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

Re: Basic question about single entry point - why my solution actually *works*?

$
0
0
Well, I'll answer myself.

It seems that the sentence "and only one location block will ever be run" is a bit not precise, because nginx obviously can run more locations if we do any kind of 'rewrite', which try_files does (kind of). The same author in the same article even mentions this (this is related to a different example in the article):

(...) The one try files line means that it will first try accessing the full URI, which means that a static file request will end here. Secondly it will try the full URI plus a slash, thus looking for a directory. Finally, if none of these are found it will send the request to /index.php **and perform a new location match**, which will of course hit our PHP location and fastcgi_pass the request

Viewing all articles
Browse latest Browse all 4759

Trending Articles



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