: Why a page that works returns a 500 error? I have this url that seems to work fine but it returns a 500 error. http://comehike.com/outdoors/hike_widget.php?hike_id=164&height=700&width=500
I have this url that seems to work fine but it returns a 500 error.
comehike.com/outdoors/hike_widget.php?hike_id=164&height=700&width=500
Any idea why that is possibly happening? I have like 10k such errors in my google webmaster tools :(
More posts by @Voss4911412
3 Comments
Sorted by latest first Latest Oldest Best
If you can create a .htaccess file (or already have one), put this code at the top:
# enable PHP error logging
php_flag log_errors on
php_value error_log /path/to/htdocs/PHP_errors.log
Create a blank PHP_errors.log file in the directory specified in your .htaccess file and set its permissions to 777. Now refresh the page that's giving the 500 error and check if that log file now contains an error(s).
HTTP response headers are separate to the actual content that is returned. You can return any page with any response code (that's how custom 404 errors work).
The problem most likely lies with your server or PHP code. Check that there is no 500 error being sent in PHP (it would use the header() function), check there are no errors in .htaccess and that your server settings are not breaking anything.
If you are on shared hosting you'll probably need to contact your host since it may be their fault.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.