.htaccess 如何使用htaccess从特定url或页面删除ssl

.htaccess 如何使用htaccess从特定url或页面删除ssl,.htaccess,ssl,.htaccess,Ssl,我有一个与ssl的网站。网站中的所有页面都通过www.https重定向到https 我希望下面的URL是非ssl的,所以它只适用于http www.domain.com/admin/order/remote_request? www.domain.com/admin/order/print/131756 我当前的htacess文件如下 <IfModule mod_rewrite.c> <IfModule mod_negotiation.c> Op

我有一个与ssl的网站。网站中的所有页面都通过www.https重定向到https

我希望下面的URL是非ssl的,所以它只适用于http

www.domain.com/admin/order/remote_request?
www.domain.com/admin/order/print/131756
我当前的htacess文件如下

<IfModule mod_rewrite.c>
    <IfModule mod_negotiation.c>
        Options -MultiViews
    </IfModule>

    RewriteEngine On

    # Redirect Trailing Slashes If Not A Folder...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)/$ /$1 [L,R=301]        

    # Redirect non www request to www
    RewriteCond %{HTTP_HOST} !^www\.
    RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]        

    # Redirect http request to https
    RewriteCond %{HTTPS} off    
    RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

    # Handle Front Controller...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.php [L]
</IfModule>

选项-多视图
重新启动发动机
#如果不是文件夹,则重定向尾部斜杠。。。
重写cond%{REQUEST_FILENAME}-D
重写规则^(.*)/$/$1[L,R=301]
#将非www请求重定向到www
重写cond%{HTTP_HOST}^www\。
重写规则^(.*)$http://www.%{HTTP_HOST}/$1[R=301,L]
#将http请求重定向到https
重写条件%{HTTPS}关闭
重写规则^(.*)$https://%{HTTP_HOST}%{REQUEST_URI}[L,R=301]
#处理前控制器。。。
重写cond%{REQUEST_FILENAME}-D
重写cond%{REQUEST_FILENAME}-F
重写规则^index.php[L]
试试:

    # Redirect http request to https
RewriteCond %{THE_REQUEST} !/admin/order/remote_request\? [NC]
RewriteCond %{THE_REQUEST} !/admin/order/print/131756 [NC]

    RewriteCond %{HTTPS} off    
    RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]