Quantcast
Channel: Nginx Forum - How to...
Viewing all articles
Browse latest Browse all 4759

serving php files from 2 locations under same server name

$
0
0
Hi

I am using nginx to server mysite.com and I also want to run a clone for testing purposes on same domain but at mysite.com/clone.

Now when I use



location /clone {
root /usr/local/nginx; #clone is folder under /usr/local/nginx
index index.php index.html;
}

and go to mysite.com/clone/index.html
I can see the html page but when i go to /mysite.com/clone/index.php, I get the option to download the php file which indicates that nginx is not passing requests to php.

How I can serve 2 php sites running under same server name but different location and root folder?

Thanks

Viewing all articles
Browse latest Browse all 4759

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>