[support] http > https redirect

sander-martijn sander at sander-martijn.com
Sun Sep 16 22:14:11 UTC 2007


Anyone know what I need to do to get individual pages to redirect to 
https? 

These 2 lines work:
RewriteCond %{SERVER_PORT} !^443$
RewriteRule ^(contact/requestBook)$ https://s24863.gridserver.com/$1 
[R=301,L]

These lines, which should be the exact opposite, redirect all pages to http:
 # Redirect non-secure pages to HTTP if requested by HTTPS
  RewriteCond %{SERVER_PORT} ^443$
  RewriteCond %{REQUEST_URI} !^contact/requestBook$
  RewriteRule ^(.*)$ http://s24863.gridserver.com/$1 [R=301,L]

I've tried all options here including node/387, index.php?q=node/387, 
including/excluding parens etc - none have worked.

Obviously as is the contact/requestBook page ends in an endless loop.

I tried the securepages module but it's broken.

.sander


More information about the support mailing list