PHP will answer “500” when it encounters a fatal error, such as E_PARSE , E_ERROR and fuzzy exceptions. 500 is the HTTP response code for "Internal Server Error" - something fatal happened while processing the request.
In your php.ini on the development machine, you should set the error_reporting level to (at least) E_NOTICE - preferably E_ALL - and make sure display_errors enabled. This will show you an error message in the browser, including for "500" errors.
You can also check your Apache error logs, errors will be indicated there if log_errors included in php.ini, By default it will be <apache_ServerRoot>\logs\error.log .
You can also manage all this at runtime ini_set() and error_reporting()
source share