因为在Fastcgi模式下,php不支持rewrite的目标网址的PATH_INFO的解析
ThinkPHP运行在URL_MODEL=2时,会出现 No input file specified.的情况,
这时可以修改网站目录的.htaccess文件:
 
RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L] 
改为 RewriteRule ^(.*)$ index.php?s=$1 [QSA,PT,L] 
 
完整的.htaccess代码为:
  1. <IfModule mod_rewrite.c>
      Options +FollowSymlinks
      RewriteEngine On
    
      RewriteCond %{REQUEST_FILENAME} !-d
      RewriteCond %{REQUEST_FILENAME} !-f
      #RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L]
      RewriteRule ^(.*)$ index.php?s=$1 [QSA,PT,L]
    </IfModule>

     

 
出处:http://tanning555.blog.163.com/blog/static/529751712013371011142/





相关文章:

  • 2022-12-23
  • 2021-06-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-30
猜你喜欢
  • 2021-10-20
  • 2021-07-16
  • 2021-10-14
  • 2022-12-23
  • 2021-11-14
  • 2022-12-23
  • 2021-11-11
相关资源
相似解决方案