Case insensitive location

Callumpy nginx-forum at
Tue Apr 8 12:55:02 UTC 2014

Hello there, i'm hoping someone can help me out with this. I've tried many
different things but none have worked for me so far.

Here is my location block:

location ^~ /card/ {
                root /home/site/public;
                rewrite ^/card/([a-zA-Z0-9_+]+)/(.*).png$
/card.php?name=$2&type=$1 last;
                expires epoch;

Some requests for images are being made with a capital 'C' in 'Card' and are
causing 404s.

I've tried changing the location to "~* ^/card/" but that didn't work, is
there anything else I could try?

Thanks in advance.

Posted at Nginx Forum:,249105,249105#msg-249105

More information about the nginx mailing list