.htaccess mod_rewrite无法使用我的简单url
问题是,我无法使用mod_重写更改我的URL,我拥有的URL是:.htaccess mod_rewrite无法使用我的简单url,.htaccess,mod-rewrite,.htaccess,Mod Rewrite,问题是,我无法使用mod_重写更改我的URL,我拥有的URL是: http://example.org/files/news.php?news=180 我希望看到这样的情况: http://example.org/files/news/180 我尝试过以下代码(每一条规则): 没什么,代码应该是什么样子??谢谢将此代码放入/files/.htaccess: ErrorDocument 404 http://mysite.org/notfound.php Options +Indexes
http://example.org/files/news.php?news=180
我希望看到这样的情况:
http://example.org/files/news/180
我尝试过以下代码(每一条规则):
没什么,代码应该是什么样子??谢谢将此代码放入
/files/.htaccess
:
ErrorDocument 404 http://mysite.org/notfound.php
Options +Indexes +FollowSymlinks -MultiViews
RewriteEngine on
RewriteBase /files/
RewriteRule ^news/([^/.]+)/?$ news.php?news=$1 [L,QSA]
ErrorDocument 404 http://mysite.org/notfound.php
Options +Indexes +FollowSymlinks -MultiViews
RewriteEngine on
RewriteBase /files/
RewriteRule ^news/([^/.]+)/?$ news.php?news=$1 [L,QSA]