help with location tag / reg ex

Ilan Berkner ilan at
Thu Dec 29 18:51:13 UTC 2011

I'd like to match all of the media files in this sub directory (and
subsequent directories) but its not working.

    location ~* /_games/\.(jpg|jpeg|png|gif|swf|flv|mp3)$ {
      expires max;

My regular expression is off the mark...

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the nginx mailing list