]> git.mjollnir.org Git - moodle.git/commitdiff
redirect(): fix protocol name in redirection header()
authormartinlanghoff <martinlanghoff>
Wed, 27 Dec 2006 01:49:14 +0000 (01:49 +0000)
committermartinlanghoff <martinlanghoff>
Wed, 27 Dec 2006 01:49:14 +0000 (01:49 +0000)
lib/weblib.php

index fe19c4b7feb4593c325f06ff220915c4bcf1b88a..92b06c4a6592c90c93297538c52087aa9be3bcdb 100644 (file)
@@ -4799,7 +4799,7 @@ function redirect($url, $message='', $delay=-1) {
 
         $delay = 0;
         //try header redirection first
-        @header('HTTP/1.x 303 See Other'); //302 might not work for POST requests, 303 is ignored by obsolete clients
+        @header($_SERVER['SERVER_PROTOCOL'] . ' 303 See Other'); //302 might not work for POST requests, 303 is ignored by obsolete clients
         @header('Location: '.$url);
         //another way for older browsers and already sent headers (eg trailing whitespace in config.php)
         echo '<meta http-equiv="refresh" content="'. $delay .'; url='. $encodedurl .'" />';