所有不存在的文件和文件夹重定向,但带有php扩展名的文件和文件夹除外

时间:2019-01-03 08:46:17

标签: php nginx easyphp nginx-config

我在我的应用程序中使用以下指令:

location / {
    root  "C:/Program Files (x86)/EasyPHP-Devserver-17/eds-www";
    index  index.php index.html index.htm;
    autoindex on;
    try_files $uri $uri/ /index.php?param=$uri;
}

使用url的$ _GET参数将所有不存在的文件和文件夹重定向到index.php,但出现以下错误的php文件除外:

  

未指定输入文件。

是否存在一种解决方法,以使其与.php扩展名兼容?

0 个答案:

没有答案