From 817163a1bcff02285f763bcf72ff02e86f218cf8 Mon Sep 17 00:00:00 2001 From: Derek Jones Date: Sat, 11 Jul 2009 17:05:58 +0000 Subject: Modified show_error() to allow sending of HTTP server response codes. Added set_status_header() to the Common functions to allow use when the Output class is unavailable. Fixed a bug where the 400 status header sent with the 'disallowed URI characters' was not compatible with CGI environments. --- system/libraries/URI.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'system/libraries/URI.php') diff --git a/system/libraries/URI.php b/system/libraries/URI.php index f09a5cd7c..efc7a18b3 100644 --- a/system/libraries/URI.php +++ b/system/libraries/URI.php @@ -188,8 +188,7 @@ class CI_URI { { if ( ! preg_match("|^[".preg_quote($this->config->item('permitted_uri_chars'))."]+$|i", $str)) { - header('HTTP/1.1 400 Bad Request'); - show_error('The URI you submitted has disallowed characters.'); + show_error('The URI you submitted has disallowed characters.', 400); } } -- cgit v1.2.3-24-g4f1b