After thinkphp5 is deployed online, view-source: you can see the source code, but http shows a blank page, a summary of the reasons and solutions

This article mainly explains: After the thinkphp5 project is deployed online view-source: you can see the source code, but http shows the reasons for the blank page and the solution tutorial
Author: Ren Congcong
Date: April 17, 2023
thinkphp version 5.1

Description of the phenomenon:

The offline test environment shows that the interface can be seen.
insert image description here
After deploying to the online configuration, the page is blank.
insert image description here
Write in php echo 1232;die;and you can see 1232
insert image description here

Problem 1. Pseudo-static

reason:

Pseudo-static rules are misconfigured, missing last;break; parameters.

Solution:

Use the correct pseudo-static below

for nginx

location / {
   
    
    
	if 

Guess you like

Origin blog.csdn.net/hj960511/article/details/130196645