From 2b23eea312d4e14352e43344dc9c5b7a5078401d Mon Sep 17 00:00:00 2001
From: moodler <moodler>
Date: Tue, 4 Nov 2003 03:35:05 +0000
Subject: [PATCH] Removed header redirect for cases where output already
 occurred (thougn it shouldn't happen)

---
 lib/weblib.php | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/lib/weblib.php b/lib/weblib.php
index c6747a567d..e5d41b017d 100644
--- a/lib/weblib.php
+++ b/lib/weblib.php
@@ -1652,8 +1652,7 @@ function redirect($url, $message="", $delay="0") {
 // Redirects the user to another page, after printing a notice
 
     if (empty($message)) {
-        sleep($delay);
-        @header("Location: $url");
+        echo "<meta http-equiv=\"refresh\" content=\"$delay; url=$url\" />";
         echo "<script>location.replace('$url');</script>";   // To cope with Mozilla bug
     } else {
         if (empty($delay)) {  
-- 
2.39.5