【发布时间】:2016-12-01 11:07:07
【问题描述】:
我遇到了一个奇怪的问题...... htaccess 规则似乎不起作用
这是我的规则:
Options +FollowSymLinks
RewriteEngine On
RewriteRule ^/([^/]+)/([^/]+)/ /index.php?view=$1&layout=$2 [NC]
无论我尝试什么都不会生效。理论上我应该可以访问 /my/test/ 并查看 index.php?view=my&layout=test 的内容
稍后在页面中强制 https:// 的重写规则确实有效,我知道服务器正在读取 htaccess。
服务器是 Centos 6 上的 VPS
有什么想法吗??
【问题讨论】:
标签: apache .htaccess mod-rewrite url-rewriting centos6