| @@ 90-103 (lines=14) @@ | ||
| 87 | ob_end_clean(); |
|
| 88 | if (isset($php_errormsg)) { |
|
| 89 | $error_info = error_get_last(); |
|
| 90 | switch ($error_info['type']) { |
|
| 91 | case E_NOTICE: |
|
| 92 | $error_level = 1; |
|
| 93 | // no break |
|
| 94 | case E_USER_NOTICE: |
|
| 95 | break; |
|
| 96 | case E_DEPRECATED: |
|
| 97 | case E_USER_DEPRECATED: |
|
| 98 | case E_STRICT: |
|
| 99 | $error_level = 2; |
|
| 100 | break; |
|
| 101 | default: |
|
| 102 | $error_level = 99; |
|
| 103 | } |
|
| 104 | if ($modx->config['error_reporting']==='99' || 2<$error_level) { |
|
| 105 | $modx->messageQuit('PHP Parse Error', '', true, $error_info['type'], $error_info['file'], $_SESSION['itemname'] . ' - Module', $error_info['message'], $error_info['line'], $msg); |
|
| 106 | $modx->event->alert("An error occurred while loading. Please see the event log for more information<p>{$msg}</p>"); |
|
| @@ 6275-6285 (lines=11) @@ | ||
| 6272 | if (isset($actionName) && !empty($actionName)) { |
|
| 6273 | $source .= $actionName; |
|
| 6274 | } |
|
| 6275 | switch ($nr) { |
|
| 6276 | case E_DEPRECATED: |
|
| 6277 | case E_USER_DEPRECATED: |
|
| 6278 | case E_STRICT: |
|
| 6279 | case E_NOTICE: |
|
| 6280 | case E_USER_NOTICE: |
|
| 6281 | $error_level = 2; |
|
| 6282 | break; |
|
| 6283 | default: |
|
| 6284 | $error_level = 3; |
|
| 6285 | } |
|
| 6286 | $this->logEvent(0, $error_level, $str, $source); |
|
| 6287 | ||
| 6288 | if ($error_level === 2 && $this->error_reporting !== '99') { |
|