Hey everybody, I'm trying to make a HTTPS redirect for my webmail so that whenever a user goes to http://www.mydomain.com/mail it is automatically redirected to https://www.mydomain.com/mail. Everything that I have tried so far causes an infinite loop. Does anyone have any good code for this?
You could use this in your apache directives for the site or in your .htaccess. Code: RewriteEngine On RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
I'm pretty sure that would create an infinite loop because there is nothing telling it to stop if it is already on https.