Linux区


apache环境php页面出现No input file specified错误的另一种原因

Linux+Apache环境打开php页面出现No input file specified错误的解决方法,网上的答案都是千篇一律的在.htaccess文件里添加index.php什么的代码,如下所示:

<IfModule mod_rewrite.c>
Options +FollowSymlinks -Multiviews
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
</IfModule>
(删除表示无效)

如果你发现这种解决方法无效,那么一种可能的原因是你用宝塔bt面板,而且刚刚修改过网站的文件夹名。解决方法是:

修改网站文件夹目录下.user.ini文件里的相应路径即可。

相关博文



发表评论

电子邮件地址不会被公开。