Answer the question
In order to leave comments, you need to log in
How to get rid of cylical request in .htaccess and make CNC?
We have a page
site.com/?id=1&bla=2&blabla=3
There are tasks for it:
1. Make a pointwise CNC, while not touching the CNC mechanism of the system at all.
2. Make a redirect from the old url to the new one
We make the rule: the
CNC works, the page is given as if located at site.com/mychpu And now we need to redirect from the old url to the new one...RewriteRule ^mychpu$ /?id=1&bla=2&blabla=3
RewriteCond %{QUERY_STRING} ^id=1&bla=2&blabla=3$
RewriteRule ^.*$ http://site.com/mychpu [R=301,L]
Answer the question
In order to leave comments, you need to log in
RewriteCond %{QUERY_STRING} ^id=1&bla=2&blabla=3$
RewriteCond %{REQUEST_FILENAME} !mychpu$
RewriteRule ^.*$ http://site.com/mychpu [R=301,L]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question