开发者

Regular Expression in RewriteRule breaks in MAMP

开发者 https://www.devze.com 2023-01-26 13:38 出处:网络
I just switched from XAMPP to MAMP and now this rewrite rule does not work anymore 开发者_运维问答RewriteRule ^([0-9]{6}+)/?$ includes/redirect.php?ref=$1 [L]

I just switched from XAMPP to MAMP and now this rewrite rule does not work anymore

开发者_运维问答RewriteRule ^([0-9]{6}+)/?$ includes/redirect.php?ref=$1 [L]

In the Appache error log:

[Mon Nov 22 13:59:24 2010] [alert] [client 172.xx.xx.x] /Applications/MAMP/htdocs/myapp/.htaccess: RewriteRule: cannot compile regular expression '^([0-9]{6}+)/?$'

Any idea's? My other rule (from redirect.php) works fine:

RewriteRule ^([0-9]{6})-.*?\.html$ templates/default/index.php?ref=$1 [L]


 [0-9]{6}+

This is an odd fragment that I suspect is the issue. You're saying exactly 6 digits, then saying one-or-more as well?

What did you want to be matched?

0

精彩评论

暂无评论...
验证码 换一张
取 消