platypuspuzzles wrote:without the pages reverting back to my primary domain.
Have you tried inserting this at the top of your .htaccess file?
Code: Select all
RewriteCond %{SERVER_PORT} ^443$
RewriteCond %{HTTP_HOST} ^subdomain\.domain\.com$ [NC]
RewriteCond %{REQUEST_URI} !^/store/
RewriteRule ^(.*) /store/$1 [L]
That's in a case where the install is in a /store/ folder, otherwise you'd have to replace them with a single slash. And if you do have your install in a folder, this goes in the root .htaccess, not Opencart's. I have a Wordpress install in my root so this is how my Opencart install is setup, and I had the same problem before adding this to the htaccess.