zoukankan      html  css  js  c++  java
  • nginx不支持pathinfo 导致thinkphp出错解决办法

    location / { 
     if (!-e $request_filename) { 
     rewrite ^(.*)$ /index.php?s=$1 last; 
     break; 
     } 
     }

    然后项目配置下url模式改为2

    'URL_MODEL'=>2,
    location ~ .php {    #去掉$
          root          H:/PHPServer/WWW;
          fastcgi_pass   127.0.0.1:9000;
          fastcgi_index  index.php;
          fastcgi_split_path_info ^(.+.php)(.*)$;     #增加这一句
          fastcgi_param PATH_INFO $fastcgi_path_info;    #增加这一句
          fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
          include        fastcgi_params;
     }
  • 相关阅读:
    Java 高级文件处理
    drf10
    drf9
    drf8
    drf7
    drf6
    drf5
    drf4
    drf3
    drf2
  • 原文地址:https://www.cnblogs.com/xmzncc/p/5943278.html
Copyright © 2011-2022 走看看