PHP not displaying errors

后端 未结 2 1302
刺人心
刺人心 2021-01-18 05:11

I have a small script which im using to test PHP mail(), as below:



        
2条回答
  •  无人及你
    2021-01-18 05:24

    According to the PHP Runtime Configuration guide:

    Note: Although display_errors may be set at runtime (with ini_set()), it won't have any affect if the script has fatal errors. This is because the desired runtime action does not get executed.

    Your code appears to have a syntax error ('test, is missing a closing apostrophe). Thus, your program is encountering a fatal error. The only way to get a fatal error to display (EDIT: outside the error log) is to set display_errors = 1 in your php.ini file.

提交回复
热议问题