summaryrefslogtreecommitdiffstats
path: root/error.php
blob: 06fcd87b9c3c2b4f9b45b7da259d19b389313a5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<?php

include_once "includes/common.inc";

$errors = array(
  500 => "500 error: internal server error",
  404 => "404 error: '". $_SERVER["REDIRECT_URL"] ."' not found",
  403 => "403 error: access denied - forbidden",
  401 => "401 error: authorization required",
  400 => "400 error: bad request"
);

if ($errors[$_SERVER["REDIRECT_STATUS"]]) {
  watchdog("httpd", $errors[$_SERVER["REDIRECT_STATUS"]]);
  header("HTTP/1.0 ". $errors[$_SERVER["REDIRECT_STATUS"]]);
}

include_once("$base_url/index.php");
?>