【发布时间】:2010-06-04 07:41:30
【问题描述】:
这是我想做的:
http://www.mysite.com/ > http://www.mysite.com/index.php
http://www.mysite.com/asd > http://www.mysite.com/index.php?page=$1
asd 将是附加到 index.php 的 $page 变量的页面的名称。
我当前的重写规则成功重定向了请求的页面,但未能加载默认的 index.php 页面。
RewriteEngine On
RewriteRule ^([\w]*)$ /index.php?page=$1 [L]
我该如何解决这个问题? :/
【问题讨论】:
标签: regex apache mod-rewrite