: How can i do multiple 302 redirects in htaccess? I'm currently using the following to redirect only 3-4 pages to new a site # Use PHP5.4 as default RewriteEngine On RewriteRule ^news1.html$ https://www.example.com/news1.html
I'm currently using the following to redirect only 3-4 pages to new a site
# Use PHP5.4 as default
RewriteEngine On
RewriteRule ^news1.html$ www.example.com/news1.html [R,L]
RewriteRule ^news2.html$ www.example.com/news2.html [R,L]
RewriteRule ^news3.html$ www.example.com/news3.html [R,L]
Options -Indexes
However only news.1html is being redirected, not the rest of them.
How do i redirect all to their subsequent new page?
More posts by @Mendez628
1 Comments
Sorted by latest first Latest Oldest Best
The easiest way to do this isn't with rewrite rules but with the redirect directive. Simply use
Redirect 301 /oldfile.htm example.net/newfile.htm
in your .htaccess file to redirect a single file from the current site to a file on another domain.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.