PHPには問題を扱う2つの並行したシステムがあります。従来型のエラー(warning、notice、fatal error)と、例外(オブジェクトベースで、try/catchでキャッチ可能)です。モダンなPHPではこの大部分を Throwable 階層の下に統一しており、良いプラクティスとしては例外の利用が推奨されます。
従来型のエラーレベル
E_NOTICE → minor issues (e.g. using an undefined variable) — script continues
E_WARNING → non-fatal problems (e.g. include of a missing file) — continues
E_ERROR / Fatal → serious errors (e.g. calling an undefined function) — script HALTS
E_DEPRECATED → use of deprecated features
