2014-07-24 75 views

回答

0
Please use bellow .htaccess rules to redirect some pages to https and other pages to http, 


RewriteEngine On 

# Force SSL on my-listing and add listing pages 
RewriteCond %{HTTPS} off 
RewriteCond %{REQUEST_URI} (my-listing|new|choose-listing-type-plans) 
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] 

# Remove SSL on other pages 
RewriteCond %{HTTPS} on 
RewriteCond %{REQUEST_URI} !\.(jpe?g?|png|gif|css|js|woff|ttf|ico|php|txt|svg) [NC] 
RewriteCond %{REQUEST_URI} !(my-listing|new|choose-listing-type-plans) 
RewriteCond %{REQUEST_FILENAME} !-f 
RewriteCond %{REQUEST_FILENAME} !-d 
RewriteRule (.*) http://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] 



Thanks, 
<h1>Nilesh G. Pangul</h1> 
@http://www.facebook.com/nileshgpangul 
相關問題