Jump to content

whats wrong with this


mga_ka_php

Recommended Posts

Everything after the question mark is the query string, I think the Redirect directive only matches against the REQUEST_URI, if you wish to redirect based on that link you will probably have to use a combination of RewriteCond and RewriteRule.

 

RewriteCond %{QUERY_STRING} form_id=123
RewriteCond %{QUERY_STRING} form_name=contact%20us
RewriteRule ^tank.php$ http://www.mydomain.com/forms/contact-us/? [R=301]

Only a theoretical one I suspect, if you really think you have a lot there is probably a flaw in your thinking/design. You should really match patterns for mod_rewrite not exact URLs. The entire process you are doing seems somewhat back to front, which is all to common with people new to mod_rewrite.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.