function redirection($location, $script = false) { if (!$script) { header("HTTP/1.1 301 Moved Permanently"); header("Location: ".str_replace("&", "&", $location)); exit; } else { echo "\n"; exit; } }