Force reporting of E_USER_* in error api

Solves the problem of Mantis silently proceeding through errors that
should effectively stop code execution, when error_reporting is disabled
in php.ini or apache mod config.

This follows @davidhicks recommendation in comment ~22998.

Fixes #10966

Backported from master cec454931df5a99d03ff22aabf8901648ff3d549.