Regex .htaccess与mod_rewirte模块的重写问题

Regex .htaccess与mod_rewirte模块的重写问题,regex,.htaccess,mod-rewrite,Regex,.htaccess,Mod Rewrite,我在html中生成了以下URL http://www.xxx.com/page/26/website-design-services?ajax=true 已配置。读取页面id值的htaccess语法为 # BEGIN Rewrite <IfModule mod_rewrite.c> RewriteEngine on #RewriteBase / RewriteRule ^page/([^/]+)/?(.*)$ page.php?section=$1 [QSA,L] </If

我在html中生成了以下URL

http://www.xxx.com/page/26/website-design-services?ajax=true
已配置。读取页面id值的htaccess语法为

# BEGIN Rewrite
<IfModule mod_rewrite.c>
RewriteEngine on
#RewriteBase /
RewriteRule ^page/([^/]+)/?(.*)$ page.php?section=$1  [QSA,L]
</IfModule>
# END Rewrite
输出为

Array
(
    [ajax] => true
)

知道它为什么没有检测到其他变量吗?

通过
httpd.conf
启用
mod\u rewrite
.htaccess
,然后将此代码放入
文档根目录/.htaccess
文件:

Options +FollowSymLinks -MultiViews
# Turn mod_rewrite on
RewriteEngine On
RewriteBase /

RewriteRule ^page/([^/]+)/ /page.php?section=$1 [NC,QSA,L]

它应该已经起作用了,你的站点上运行了PHP/CMS框架吗?不,我没有使用框架,可能是内部的东西,例如http.conf值没有正确设置,但是对于另一个站点来说,重写托管在同一个apache 2.2服务器上的URL工作正常…奇怪,我编辑了我的代码来完成。htaccess和简化规则。现在可以尝试编辑代码了吗?很可能是因为关闭了“多视图”
Options +FollowSymLinks -MultiViews
# Turn mod_rewrite on
RewriteEngine On
RewriteBase /

RewriteRule ^page/([^/]+)/ /page.php?section=$1 [NC,QSA,L]