​thinkphp迁移到linux后出现500错误怎么办?

PHPz
Release: 2020-06-18 10:01:11
Original
1387 people have browsed it

​thinkphp迁移到linux后出现500错误怎么办?

thinkphp迁移到linux后出现500错误怎么办?

公司团队项目,习惯了Linux开发环境,接手项目之后发现,除了首页的index方法,控制器的其他方法无法打开。

权限,大小写全部检查正常,然后发现了解决方法:

开启fastcgi模式之后,.htacess的重写规则要改。把原来的

RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
Copy after login

改为

RewriteRule ^(.*)$ /index.php?/$1 [L]
Copy after login

然后就可以正常访问了

推荐:《thinkphp框架

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!