Apache 2.4.56 MOD_REWRITE 不适用于 /cgi-bin/

问题描述 投票:0回答:0

1.) 我有一个与文件 C:\xampp\htdocs\.htaccess 中的 MOD_REWRITE 相关的问题。

它似乎在除 /cgi-bin/ 之外的任何目录中都能正常工作。

例如,当我尝试使用以下 RewriteRule 从 http:// 切换到 https:// 时:

RewriteCond %{SERVER_PORT} !^443$

RewriteRule (.*) https://%{HTTP_HOST}/$1 [R=301,L]

对于像这样的 URL,它不会切换到 https://:http://localhost/cgi-bin/test.cgi

虽然对于像这样的 URL 来说它做得很好:http://localhost/test.html

2.) 我的 C:\xampp pach 有问题吗

apache mod-rewrite cgi-bin s3-rewrite-rules
© www.soinside.com 2019 - 2024. All rights reserved.