Brendan Tully0 Comments
July 2, 2022
Here’s a quick fix if you’re trying to get .htaccess 301 redirects working on a site that was built using Frontpage (ugh)
Ordinarily I just cut and paste some code from our internal doco to redirect domain.com to www.domain.com in .htaccess files and all is sweet but unusually I was getting a 403 error with access to / denied on this old site I was working in that was built with Frontpage.
Took me about half an hour of Googlingering to work out that Frontpage sites don’t like .htaccess being played with.
So simple fix, add the line “Options +FollowSymLinks” before your rewrite rules. My rewrite code in .htaccess looks like this now:
Options +FollowSymLinks RewriteEngine On RewriteBase / RewriteCond %{HTTP_HOST} ^domain.com [NC] RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,L]
I added this at the end of the file after all the rubbish that Frontpage adds to the htaccess file.
Give it a try, let me know how you go!
* Denotes Required Field