// todo: remove FA font usage and use SVGs // todo: utilize the social module so that each network has multiple icons + store share button links // todo: make a /public folder to separate source code from publicly-accessible assets //---------------------------------------- // epicPlatform // (c) Epic Web Studios, LLC //---------------------------------------- // For the latest releases, please visit: // https://github.com/epicwebstudios/epicPlatform //---------------------------------------- use EWS\mysqlim\mysqlim; use EWS\Theme\ThemeHandler; register_shutdown_function(function() { $error = error_get_last(); if (!$error) { ob_end_flush(); return; } $exceptions = [ E_ERROR => 'E_ERROR', E_WARNING => 'E_WARNING', E_PARSE => 'E_PARSE', E_NOTICE => 'E_NOTICE', E_CORE_ERROR => 'E_CORE_ERROR', E_CORE_WARNING => 'E_CORE_WARNING', E_COMPILE_ERROR => 'E_COMPILE_ERROR', E_COMPILE_WARNING => 'E_COMPILE_WARNING', E_USER_ERROR => 'E_USER_ERROR', E_USER_WARNING => 'E_USER_WARNING', E_USER_NOTICE => 'E_USER_NOTICE', E_STRICT => 'E_STRICT', E_RECOVERABLE_ERROR => 'E_RECOVERABLE_ERROR', E_DEPRECATED => 'E_DEPRECATED', E_USER_DEPRECATED => 'E_USER_DEPRECATED', E_ALL => 'E_ALL' ]; $terrible_exceptions = [ E_ERROR, E_PARSE, E_CORE_ERROR, E_USER_ERROR, E_COMPILE_ERROR, E_RECOVERABLE_ERROR, ]; if (!in_array($error['type'], $terrible_exceptions)) { ob_end_flush(); return; } while (ob_get_level()) ob_end_clean(); $error_type = $exceptions[$error['type']] ?? 'Unknown'; $error['message'] = nl2br(htmlspecialchars($error['message'])); echo <<
$error_type
$error[file]
$error[line]
$error[message]