url rewrite help

Roxis roxis at list.ru
Sat Dec 8 20:35:07 MSK 2007


On Saturday 08 December 2007, rkmr.em at gmail.com wrote:
> hi
> i am moving from lighttpd to nginx, and I had this rewrite in lighttd. how
> do i do this in nginx?
>
>    "^/[^/]+\.xml$" => "/static$0",
>
> i tried and dint work
>   rewrite    ^/[^/]+\.xml$  /static$1;
>
> how do i fix this?
> thanks  a lot!

rewrite    ^(/[^/]+\.xml)$  /static$1;





More information about the nginx mailing list