I wrote a simple php code and uploaded it to the space. However, the error 500 is displayed in apache. Google's solutions basically mean that there is a problem with file permissions. But I have read that the File Permission is 644, And the directory permission is 755. Later, another PHP file was created in the same directory and written to [code]? Phpe
I wrote a simple php code and uploaded it to the space. However, the error 500 is displayed in apache. Google's solutions basically mean that there is a problem with file permissions. But I have read that the File Permission is 644, And the directory permission is 755. Later, another PHP file was created in the same directory and written to [code lang = "js"]? Php e
I wrote a simple php code and uploaded it to the space. However, the error 500 is displayed in apache.
Google's solutions basically mean that there is a problem with file permissions. But I have read that the File Permission is 644, And the directory permission is 755.
Create another PHP file in the same directory and write
[Code lang = "js"]
Echo "test ";
?> [/Code]
No error occurs. The problem must be in the content of the target PHP file. Put the modified file in the local apache and execute it. It is found that there is less ";" after a statement. After a semicolon is added, no Error 500 is displayed. The execution is successful!
It is found that there are still many restrictions on the VM, especially the http header reply contains apache and php versions. However, this blog does not have much to do with it. If you love to attack, come on. After a while, I put my blog into vps when I was familiar with linux.
Original article address: Cause and solution of Error 500 on the php virtual host. Thank you for sharing it with me.