HTTP ERROR 500
HTTP ERROR 500 means that some kind of error occurred while trying to serve the page from the server. There are plenty of reasons why a HTTP ERROR 500 could occur. Here are some things you could do if you see one:
Enable PHP error reporting
Most HTTP ERROR 500 messages are caused by an error in your code. To see what’s going wrong, you could try to enable PHP errors.
The easiest way to do so is by going to your control panel, then PHP Config -> select your domain name -> Alter PHP Directives -> set Display Errors to On -> click Alter PHP Directives. Now, try to reload the page and see if an error message occurs.
If you still get a blank error page, you could try to manually override the error settings in your script. To do so, add the following code to the start of your script:
ini_set('display_errors', 1); ini_set('display_startup_errors', 1); error_reporting(E_ALL);
If that doesn’t work either, it’s likely your script is overriding these settings and is hiding errors from you. Some scripts provide a debug mode toggle which you can enable to make the script show more descriptive error messages.
In Wordpress, for example, you can find the line
define('WP_DEBUG', false); in the
wp-config.php file. Change this line to
define('WP_DEBUG', true);, and Wordpress will show detailed error messages. However, the exact steps vary depending on the script.
With this method, you should be able to get a real error message which will help you figure out what’s causing the issue.