Rewrite

tseveendorj tseveendorj at on-air.mn
Tue Apr 5 11:11:44 UTC 2016


Hello,

I cannot do following

request URL is http://domain.com/x4Zbs5B
It should be http://domain.com/index.php?download=x4Zbs5B

I tried
location / {
                 rewrite ^/([^/][a-zA-Z0-9]+)$ /index.php?download=$1 break;
                 try_files $uri $uri/ /index.php?download=$uri;
         }
but it is downloading index.php file itself :D

how to on nginx ?




More information about the nginx mailing list