Mod rewrite mod REWRITE出现500错误,看不出有什么问题?

Mod rewrite mod REWRITE出现500错误,看不出有什么问题?,mod-rewrite,Mod Rewrite,到目前为止,我一直在使用mod re write ok Options +FollowSymLinks RewriteEngine On RewriteCond %{SCRIPT_FILENAME} !-d RewriteCond %{SCRIPT_FILENAME} !-f RewriteRule ^/?(shopping-catalogue)/([0-9]+) index.php?friendly_url=$1&view=catalogue&catalogue_id=$2

到目前为止,我一直在使用mod re write ok

Options +FollowSymLinks
RewriteEngine On
RewriteCond %{SCRIPT_FILENAME} !-d
RewriteCond %{SCRIPT_FILENAME} !-f

RewriteRule ^/?(shopping-catalogue)/([0-9]+) index.php?friendly_url=$1&view=catalogue&catalogue_id=$2 [L]
RewriteRule ^/?(shopping-catalogue)/(category)/([0-9]+) index.php?friendly_url=$1&view=$2&category_id=$3 [L]
RewriteRule ^/?(shopping-catalogue)/(category-item)/([0-9]+) index.php?friendly_url=$1&view=$2&category_item_id=$3 [L]
RewriteRule ^/?(shopping-catalogue)/(category-item-option)/([0-9]+) index.php?friendly_url=$1&view=$2&category_item_option_id=$3 [L]

# marketing module see newsletter before sending
RewriteRule ^/?(newsletters)/([A-Za-z0-9-]+)/(newsletter)\.html /newsletters/$2/newsletter.html [L]


RewriteRule .([^/]+)\.html index.php [L]


#RewriteRule ^/client-area/CLID/([0-9]+) /index.php?temp=template_dataroom&CLID=$1 [L]


# allow access with no restrictions to local machine at 192.168.1.3
RewriteCond %{REMOTE_ADDR} !192.168.1.3


# allow access to all .css and .js in sub-directories..
RewriteCond %{REQUEST_URI} !\.css$
RewriteCond %{REQUEST_URI} !\.js$

# allow access to the files inside img/, but not a directory listing..
RewriteCond %{REQUEST_URI} !dataroom/(.*)\.
RewriteRule ^files/([^/]+)/([^/]+).zip /download.php?section=$1&file=$2 [NC]
# allow access to these particular files...
我的问题似乎是这条线被忽略了

# marketing module see newsletter before sending
RewriteRule ^/?(newsletters)/([A-Za-z0-9-]+)/(newsletter)\.html /newsletters/$2/newsletter.html [L]
我试图直接访问一个html文件,但每次文件夹都是唯一的名称。。。。即

http://www.awebsite.co.uk/newsletters/template_4fd09c5b429ea/newsletter.html
这一行被忽略了。我不明白为什么

任何帮助都将不胜感激

谢谢


安迪

好的,我现在开始工作了,。已断开/断开重定向链接

这是我现在的电话线

# marketing module see newsletter before sending
RewriteRule ^/?(newsletters)/([A-Za-z0-9_]+)/(newsletter)\.html newsletters/$2/newsletter.html [L]
谢谢


Andi

我没有检查结果,但您似乎不允许下划线

RewriteRule ^/?(newsletters)/([A-Za-z0-9-]+)/(newsletter)\.html /newsletters/$2/newsletter.html [L]

RewriteRule (newsletters)/([A-Za-z0-9|-|_]+)/(newsletter)\.html /newsletters/$2/newsletter.html [L]

另外,我认为不需要以位(^)开头。

好的,我更新了它以包含下划线字符,现在我得到一个500错误。