1. 程式人生 > >http跳轉htts的htaccess文件設置

http跳轉htts的htaccess文件設置

options order rom rul htaccess serve mod host eba

RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R,L]
Options +FollowSymLinks
order allow,deny
allow from all
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteCond %{SERVER_PORT} !^443$
RewriteRule (.*) https://%{SERVER_NAME}/$1 [R=301,L]
</IfModule>

http跳轉htts的htaccess文件設置