Nginx rewrite help

hi
how do i do this rewrite in nginx? can you help me out

id.quiz.xx.comquiz.xx.com/?quiz_id=id

thanks a lot!

On Wed, Jun 09, 2010 at 10:32:21AM -0700, kevin wrote:

hi
how do i do this rewrite in nginx? can you help me out

id.quiz.xx.comquiz.xx.com/?quiz_id=id

server {
    server_name  ~^(?<id>.+)\.quiz\.xx\.com$;
    rewrite      ^  http://quiz.xx.com/?quiz_id=$id;
}


Igor S.
http://sysoev.ru/en/