Reputation: 10101
For example, to match all files (not jpg, png, gif) under the path common
, e.g.
matched:
/common/foo.php
/common/foo.doc
not matched:
/common/foo.jpg
/common/foo.gif
/foo
Currently I am using:
\/common\/.*^(?:jpg|png|gif)$
Upvotes: 1
Views: 1054
Reputation: 15110
location /common/ {
# here configuration for not jpg, png, gif
location ~ \.(?:png|gif|jpg)$ {
# here configuration for jpg, png, gif
}
}
Upvotes: 0