Fernanditos
asked on
Removing URL parameter via .htaccess
Hi,
In my Google Analytics incoming reports I have lot of urls with a NOT MINE url parameter added at end that is leading to a page not found error:
For example:
/search/pdf/ejercicios+de+ las+7+herr amientas+d e+calidad? fb_xd_frag ment=
When the right URL is /search/pdf/ejercicios+de+ las+7+herr amientas+d e+calidad
As you see the "?fb_xd_fragment=" is added at the end of my URL.
It seems to be a facebook button issue: http://www.google.com/search?q=fb_xd_fragment+fix&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a
But what i want is to redirect this:
/search/pdf/ejercicios+de+ las+7+herr amientas+d e+calidad? fb_xd_frag ment=
to this: /search/pdf/ejercicios+de+ las+7+herr amientas+d e+calidad
How can I do this from my htaccess ?
Please help!!
thank you
In my Google Analytics incoming reports I have lot of urls with a NOT MINE url parameter added at end that is leading to a page not found error:
For example:
/search/pdf/ejercicios+de+
When the right URL is /search/pdf/ejercicios+de+
As you see the "?fb_xd_fragment=" is added at the end of my URL.
It seems to be a facebook button issue: http://www.google.com/search?q=fb_xd_fragment+fix&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a
But what i want is to redirect this:
/search/pdf/ejercicios+de+
to this: /search/pdf/ejercicios+de+
How can I do this from my htaccess ?
Please help!!
thank you
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
@fernanditos: You are not forced to close a question if you have outstanding dialog. You can explain a little more or ask clarifying questions.
@Fernanditos: just wanna help you out, it's not about points here. I could have helped you better if you had clarified your question since the beginning :)
In your case, try
RewriteEngine On
RewriteCond %{QUERY_STRING} ^fb_xd_fragment=$
RewriteRule ^(.*)$ /$1? [R=301,L]
In your case, try
RewriteEngine On
RewriteCond %{QUERY_STRING} ^fb_xd_fragment=$
RewriteRule ^(.*)$ /$1? [R=301,L]
ASKER