Answer the question
In order to leave comments, you need to log in
Why does the redirect in .htaccess not work as it should?
Good afternoon. Please tell me. I changed the domain of the site. You need to make a 301 redirect. I wrote the following in .htaccess:
RewriteEngine on
RewriteCond %{HTTP_HOST} ^uk-rost\.com
RewriteRule ^(.*)$ build-74.ru/$1 [R=301,L]
RewriteCond %{HTTP_HOST} ^www.uk -rost\.com
RewriteRule ^(.*)$ build-74.ru/$1 [R=301,L]
And it redirects from any page of the old domain only to the main page of the new domain. It seems to be redirecting to the appropriate page. The structure of the site has not changed.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question