Pekeltje
By:
Pekeltje

NGINX Rewrite makes sitemap.xml and others unable to load

May 26, 2016 526 views
Nginx PHP

Hello,

I use a rewrite and now site.com/index.php?page=contact is site.com/contact
But now site.com/sitemap.xml and some others doesnt work anymore.

I use this:

rewrite ^/([^_]*)$ /index.php?page=$1 last;

How can i change this to keep the friendly url but make other things like sitemap avaible too

Be the first one to answer this question.