虚拟主机中的RewriteRule可以正常使用html,但不适用于https

时间:2014-03-27 10:32:36

标签: apache mod-rewrite virtualhost httpd.conf

我需要将重写从/applications.html更改为https://wcmportal.company.be/wps/myportal/intranet/intranet/landing/gprsportal,并且我使用以下代码进行操作

<VirtualHost *:443>
    ServerName wcmportal.company.be
    SSLEnable
    RewriteEngine on
    RewriteCond %{http:iv-remote-address} ^((10)\.(40)\.(62)\.(13))$
    # RewriteRule ^(.*)$ https://wcmportal.company.be/wps/myportal/intranet/intranet/landing/gprsportal/$1 [PT,L]
    RewriteRule ^(.*)$ /applications.html [PT,L]
</VirtualHost>

RewriteRule到/applications.html工作正常,但前一行RewriteRule到https://wcmportal.company.be/wps/myportal/intranet/intranet/landing/gprsportal/ $ 1无法正常工作。

所以我认为RewriteCond是正确的但是对https://的RewriteRule是不正确的。

0 个答案:

没有答案
相关问题