I'm new to nginx server.
I'm gonna deploy the php framework such as codeigniter to the nginx server.
My config file is following.
server { index index.html index.php index.htm; # set expiration of assets to MAX for caching location ~* \.(ico|css|js|gif|jpe?g|png)(\?[0-9]+)?$ { expires max; log_not_found off; } location / { # Check if a file exists, or route it to index.php. try_files $uri $uri/ /index.php; } location ~* \.php$ { fastcgi_pass unix:/var/run/php/php7-fpm.sock; fastcgi_index index.php; fastcgi_split_path_info ^(.+\.php)(.*)$; include fastcgi_params; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; } } My question is following.
1)The request uri is like this "www.domain.com/controllername/functionname/param1/param2/"
How does nginx work with this url?
2)The third location block matches the regular expression ".php$".
Is this true only if the uri has ended with ".php"?
(I think so , but that block's fastcgi_split_path_info has different regular expression.)