php配置.htaccess文件如下:
方法1:配置将所有http 80的访问转换为https的访问
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{SERVER_PORT} 80
RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [L,R]
</IfModule>
方法2:将特定的http访问路径,转换为指定的https的访问
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{SERVER_PORT} 80
RewriteCond %{HTTP_HOST} ^job.92bear.com/wap [NC]
RewriteRule ^(.*)$ https://job.92bear.com/wap [R,L]
</IfModule>
持续完善,待续...