How to debug “internal server error”?

2019-02-23 12:17发布

When you do changes to .htaccess files and something is wrong with it you get "Internal server error". That doesn't help me. How can I find out what's the actual error?

2条回答
地球回转人心会变
2楼-- · 2019-02-23 13:01

In the case it is a syntax error, enabling debug may not help you. If you can, run built-in php syntax checker to ensure your file is free from errors:

>> php -l path/to/your/file.php
查看更多
Viruses.
3楼-- · 2019-02-23 13:10

Error cause should be saved in server logs. Where it's exactly depends on your server and settings.

Eg. in apache2 log file is defined in ErrorLog in your config or in virtual host.

查看更多
登录 后发表回答