Forum
Issue with domain redirect
I have a client website that previously was a html site that I am replacing with a perch install. To get the site ready for go live I put the new perch site on the server inside a v3 folder and pointed a staging domain to it. I am now trying to put the site live.
I was hoping to just do a htaccess rewrite to the v3 folder rather than moving and deleting everything but when I use the following the page content disappears. Is there something wrong with my htaccess or do I need to move it out of the v3 folder for it to work?
RewriteEngine on
# Security
Options -Indexes
# Rewrite to the active site
RewriteCond %{REQUEST_URI} !^/v3/
RewriteRule ^(.*)$ /v3/$1
You need to point a subdomain to the site so that root stays as root. Perch is now seeing your pages inside a subfolder, a rewrite rule doesn't change where they actually are.