在Apache中(不支持mod_rewrite)我可以利用URI的像這樣的:NGINX路徑分隔符/解析
/module/erp/service.php/application/workorder/list?start=0&limit=25
我有什麼配置或更改nginx的支持呢?
server {
listen 80;
root /usr/share/nginx/www/web/public;
index index.php index.html;
server_name apps.mydomain.com;
location/{
try_files $uri $uri/ /index.html;
}
#error_page 404 /404.html;
#error_page 500 502 503 504 /50x.html;
#location = /50x.html {
# root /usr/share/nginx/www;
#}
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
}
有人可以告訴我可能需要添加什麼才能達到此要求嗎?
P.S,我需要填充$ _ SERVER [ 'PATH_INFO']就像在Apache存在,以及...
編輯|
我相信我發現我的答案在這裏:
https://askubuntu.com/questions/164627/nginx-php-fpm-access-denied-error
然後我遇到了 「拒絕訪問」,這聽起來像是決心是在這裏:
https://askubuntu.com/questions/164627/nginx-php-fpm-access-denied-error
任何想法?