Redirect https to http except cgi-bin
There is a need to redirect https to http except cgi-bin as the client's security certificate applies to the entire site and Google is indexing https pages as duplicates of the http instances. We wish the cgi-bin to be https for the login and checkout process as defined in business settings.
There is an elegant fix from Dave Finlayson here: http://community.sellerdeck.com/showthread.php?t=47675
but I wondered if this htaccess redirect would work:
I have not been able to test it yet, please could anyone see if it looks OK or whether I have made any gaffs?
Thank you
There is a need to redirect https to http except cgi-bin as the client's security certificate applies to the entire site and Google is indexing https pages as duplicates of the http instances. We wish the cgi-bin to be https for the login and checkout process as defined in business settings.
There is an elegant fix from Dave Finlayson here: http://community.sellerdeck.com/showthread.php?t=47675
but I wondered if this htaccess redirect would work:
Code:
RewriteCond %{HTTPS} on RewriteCond %{REQUEST_URI} !^cgi-bin($|/) RewriteRule ^(.*)$ http://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
Thank you