Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Httpd Wiki" for change 
notification.

The following page has been changed by RichBowen:
http://wiki.apache.org/httpd/RewriteHTTPToHTTPS

------------------------------------------------------------------------------
  # This will enable the Rewrite capabilities
  
  RewriteCond %{HTTPS} !=on
- # This basically checks to make sure the connection is not already HTTPS
+ # This checks to make sure the connection is not already HTTPS
  
  RewriteRule ^(.*) https://%{SERVER_NAME}$1 [R,L]
  # This rule will redirect users from their original location, to the same 
location but using HTTPS.
@@ -37, +37 @@

  # This will enable the Rewrite capabilities
  
  RewriteCond %{HTTPS} !=on
- # This basically checks to make sure the connection is not already HTTPS
+ # This checks to make sure the connection is not already HTTPS
  
- RewriteRule ^secure/(.*) https://%{SERVER_NAME}/secure/$1 [R,L]
+ RewriteRule ^/?secure/(.*) https://%{SERVER_NAME}/secure/$1 [R,L]
  # This rule will redirect all users who are using any part of /secure/ to the 
same location but using HTTPS.
  # i.e.  http://www.example.com/secure/ to https://www.example.com/secure/
  # This means if you dont want to force HTTPS for all directories you can 
force it for a specific sub-section of the site.

Reply via email to