Im having some issues with htaccess rewrites i need to redirect different parts of my site to https rather than http, for example login and news sections. Im not sure how to go about doing this in the correct mannor.
So at the moment I have
RewriteRule ^login/?$ index.php?p=login [R,L]
I would like to redirect this to https, I have tried the following but it doesnt seem to work
RewriteRule ^login/?$ https://%{SERVER_NAME}/index.php?p=login [R,L]
But it doesnt seem to work. am i missing something? I have rewrite on and all other settings as they work. What am I missing?
Also is there anyway to get htaccess to use a different set of rules it https is set to when it is not?
Update:
So what I want to do is rewrite http://www.site.tld/login/ rewrite to https://www.site.tld/login/code and then further rewrite to https://www.site.tld/index.php?p=login. So the user sees: https://www.site.tld/login/ but it is actually doing https://www.site.tld/index.php?p=login
/codepart for in the middle step? – w3d Jan 20 at 16:48