Advanced rewrite rules
After inserting this into my .htaccess for http://www.domain.com/secure/.htaccessRewriteEngine On
RewriteCond %{SERVER_PORT} !^443$ [OR]
RewriteCond %{HTTP_HOST} !^www\.domain\.com [NC]
RewriteRule ^(.*)$ https://www.domain.com/secure/$1 [R,L]
I goto http://www.domain.com/secure/ and it takes me to https://www.domain.com/secure/
However, when I go to http://www.domain.com/secure
It redirects me to https://www.domain.com/secure//home/username/public_html/secure
Also, when I goto http://www.domain.com/secure/anotherpage
It takes me to https://www.domain.com/secure/anotherpage
which is correct.
I basically want to make all URLs on the /secure folder to use https instead of http.
--
Also, I would like to make a condition, where when the address is http://www.domain.com/secure/another-page-thats-not-secure.php to not rewrite to https
This is just one page that needs to be unsecure.