mod_rewrite syntax issue

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
User avatar
Benjamin
Site Administrator
Posts: 6935
Joined: Sun May 19, 2002 10:24 pm

mod_rewrite syntax issue

Post by Benjamin »

Is something wrong with this? It works on one server, but not on another.

Code: Select all

RewriteRule ^([^/]*?)\.html display.php?query=$1 [L]
User avatar
Benjamin
Site Administrator
Posts: 6935
Joined: Sun May 19, 2002 10:24 pm

Post by Benjamin »

I'm getting an internal server error on this as well. The error log is saying that it can't parse the regex, but it works on a different server.
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

Maybe try moving hte *? outside the parentheses. Did this regex run on another server running the same software?

Does mod_rewrite use PECL syntax? If so, you could try throwing this through a php script & see if it gives you a more descriptive error.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
Post Reply