Tuesday, January 9, 2018

mod rewrite - Adding an exception to https redirect (mod_rewrite)

I am using the the following script to redirect all requests send to http to https



RewriteEngine On



RewriteCond %{HTTPS} off



RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}



I need to add an exception to this rule (for a specific page) for the reason that it's loading a js that it's on a server that does not have https. In FF, Chrome, it works. In IE it displays a nasty warning.




Any ideas on how to add a rule to my existing mod_rewrite code?

No comments:

Post a Comment