donkey199024 2014-01-22 23:23
浏览 75
已采纳

将所有请求重定向到非www ssl https [关闭]

I need a very simple .htaccess to redirect all requests from

http://puaction.com

http://www.puaction.com

https://www.puaction.com

to

https://puaction.com

  • 写回答

2条回答 默认 最新

  • donglugou6652 2014-01-23 00:32
    关注

    Try adding these rules to the htaccess file in your document root (for the puaction.com domain):

    RewriteEngine On
    RewriteCond %{HTTPS} off [OR]
    RewriteCond %{HTTP_HOST} ^www\. [NC]
    RewriteRule ^(.*)$ https://puaction.com/$1 [L,R]
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?