We recently moved our Drupal code to a newly created 'public_html' folder for some reasons and set up the website. But then, our website was showing a 500 Internal Server Error.
The interesting part was that, we were actually able to run an HTML file and only php was throwing error. So there was something wrong with the configurations. One should check the server log, to find more about the error and here are the details we found:
[Tue Jul 14 01:43:35 2015] [error] [client 22.214.171.124] File does not exist: /home/user/public_html/500.shtml [Fri Jul 10 02:23:35 2015] [error] [client 126.96.36.199] SoftException in Application.cpp:603: Directory "/home/user/public_html" is writeable by group
This says 'public_html' can be written to by our user's 'group', meaning that the internal server error occured due to an incorrect permission of the 'public_html' folder.
The permission was '0775'.
For fixing this issue,
we changed the permission to '0755'.
You can change permissions with the File Manager from cPanel or with the help of an FTP client or using the chmod command via SSH.