function error_handler($errno, $errstr, $file, $line) {
global $messages, $go_debug;
+ // skip well known warnings we don't care about.
+ // Please use restrainedly to not risk loss of important messages
+ $excluded_warnings = array('html_entity_decode', 'htmlspecialchars');
+ foreach($excluded_warnings as $ref) {
+ if (strpos($errstr, $ref) !== false) {
+ return true;
+ }
+ }
+
// error_reporting==0 when messages are set off with @
if ($errno & error_reporting())
$messages[] = array($errno, $errstr, $file, $line);
if ($exit_if_error)
{
- echo "<br><br>";
- exit;
+ end_page(); exit;
}
}
return $db_error;