Nginx Rewrite working except for root directory -


I would like to pass all requests that do not match on a file from / framework / root / for all requests except for example http: //

// localhost .

This is my Nginx configuration:

PS: Only today the NGX coming from the upgrade has been started.

  server {80 says; Root / var / www / html; Server_name localhost; Location / {try_files $ uri $ uri / @ root; } Place @ Route {rewrite ^ (. *) $ / Framework / root.php? Path = $ 1; } # 127.0.0.1:9000 To pass the PHP scripts to the FastCGI server at the place ~ \ .php $ {try_files $ uri = 404; Fastcgi_pass Unix: /var/run/php5-fpm.sock; Fastcgi_index index.php; Fastcgi_param SCRIPT_FILENAME $ document_root $ fastcgi_script_name; Includes fastcgi_params; } # .htaccess denies access to files, if Apache's documentation is related to a # location of route # NGN ~ ~ / ..ht {reject all; }}    

OUO found

try_files $ Uri $ uri / @root; should be try_files $ uri @root; without $ uri / part because it matches the base / directory.

Comments

Popular posts from this blog

ios - Adding an SKSpriteNode to SKScene from a child SKSpriteNode -

Matlab transpose a table vector -

c# - Textbox not clickable but editable -