apache服务器出现No input file specified.解决方案

APACHE服务器出现No input file specified.解决方案 thinkcmf程序默认的.htaccess里面的规则:

复制代码
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L]
</IfModule>

"No input file specified.",是没有得到有效的文件路径造成的。

修改伪静态规则,如下:

复制代码
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
</IfModule>

就是正则结果"/$1"前面多加了一个"?"号。。

相关推荐
悄悄敲敲敲11 分钟前
Linux:进程间通信->共享内存
linux·运维·服务器
绵绵细雨中的乡音19 分钟前
Linux进程学习【环境变量】&&进程优先级
linux·运维·学习
天下·第二30 分钟前
【Nginx】负载均衡配置详解
运维·nginx·负载均衡
GanGuaGua1 小时前
linux:进程的替换
linux·运维·服务器
梓䈑2 小时前
【Linux系统】详解Linux权限
linux·运维·bash
Mr_sun.2 小时前
Day23-Web开发——Linux
linux·运维·服务器
极小狐2 小时前
如何创建并使用极狐GitLab 部署令牌?
运维·git·ssh·gitlab·github
席万里3 小时前
Go语言企业级项目使用dlv调试
服务器·开发语言·golang
高峰君主3 小时前
全栈自动化:从零构建智能CI/CD流水线
运维·ci/cd·自动化
IT运维爱好者4 小时前
Ubuntu 22.04.4操作系统初始化详细配置
linux·运维·服务器·ubuntu