From be56ab1693779dc838d8d2da21f9a52857003ccd Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 24 May 2011 17:09:38 +0000 Subject: [PATCH] Spiders can handle 302 replies nicely these days ... --- inc/functions.php | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/inc/functions.php b/inc/functions.php index 45fb99ea6c..da112b43fa 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -550,17 +550,8 @@ function redirectToUrl ($URL, $allowSpider = true) { //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'URL=' . $URL); //* DEBUG: */ die($URL); - // Simple probe for bots/spiders from search engines - if ((isSpider()) && ($allowSpider === true)) { - // Set HTTP-Status - setHttpStatus('200 OK'); - - // Set content-type here to fix a missing array element - setContentType('text/html'); - - // Output new location link as anchor - outputHtml('' . secureString($URL) . ''); - } elseif (!headers_sent()) { + // We should not sent a redirect if headers are already sent + if (!headers_sent()) { // Clear output buffer clearOutputBuffer(); -- 2.30.2