Problems with some rewrite

revirii nginx-forum at
Tue Aug 24 12:45:52 MSD 2010

I've simplified the last rule a bit, to see where the problem might be.

rewrite "^/img/default/([0-9] {3})([0-9]
{3})/(.*)\.(gif|jpg|jpeg|png|tiff|bmp)$" break;
rewrite "^/img/default/(.*)/(.*)\.(gif|jpg|jpeg|png|tiff|bmp)$" break;

So i replaced (-?[0-9] {3})(-?[0-9] {3})(-?[0-9]+) with (.*), and now
the rule works. So the problem is here: (-?[0-9] {3})(-?[0-9]

I took/adapted this rule from , but for some (to
me unknown) reasons it isn't working. Any idea?

well, nginx version: 0.6.32, debian lenny.

Posted at Nginx Forum:,123057,123068#msg-123068

More information about the nginx mailing list