Answer the question
In order to leave comments, you need to log in
How to redirect from one page to another using .htaccess?
Hello dear gentlemen!
How to make it so that if a person visits a link like: www.mysite.ru/test.aspx the .htaccess file would redirect him to the same html page ( www.mysite.ru/test.html)
There is a .htaccess code:
RewriteCond %{REQUEST_URI} ^/test.aspx$
RewriteRule ^.*$ http://mysite.ru/test.html? [R=301,L]
Answer the question
In order to leave comments, you need to log in
RewriteCond %{REQUEST_URI} ^(.*)\.aspx$
RewriteRule ^.*$ http://mysite.ru/%1.html? [R=301,L]
Found another way:Redirect 301 /test.aspx http://mysite.ru/test/
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question