=$errorTitle;?>
); ?>images/<?=$errorImage;?>.png)
setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); // Some PHP config stuff ini_set("display_errors", 1); ini_set("error_reporting", E_ALL | E_STRICT); foreach(loadAppearance() as $key => $value) { $$key = $value; } $requested = (isset($_SERVER['HTTPS']) ? "https" : "http") . "://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]"; $status = (isset($_GET['error'])?$_GET['error']:404); $codes = array( 400 => array('Bad Request', 'The server cannot or will not process the request due to an apparent client error.', 'sowwy'), 401 => array('Unauthorized', 'You do not have access to this page.', 'sowwy'), 403 => array('Forbidden', 'The server has refused to fulfill your request.', 'sowwy'), 404 => array('Not Found', $requested . ' was not found on this server.', 'confused'), 405 => array('Method Not Allowed', 'The method specified in the Request-Line is not allowed for the specified resource.', 'confused'), 408 => array('Request Timeout', 'Your browser failed to send a request in the time allowed by the server.', 'sowwy'), 500 => array('Internal Server Error', 'The request was unsuccessful due to an unexpected condition encountered by the server.', 'confused'), 502 => array('Bad Gateway', 'The server received an invalid response from the upstream server while trying to fulfill the request.', 'confused'), 503 => array('Service Unavailable', 'The server is currently unavailable (because it is overloaded or down for maintenance).', 'confused'), 504 => array('Gateway Timeout', 'The upstream server failed to send a request in the time allowed by the server.', 'confused'), 999 => array('Not Logged In', 'You need to be logged in to access this page.', 'confused'), ); $errorTitle = $codes[$status][0]; $message = $codes[$status][1]; $errorImage = $codes[$status][2]; ?>