#31340 [Opn->Bgs]: Notice: Undefined variable: HTTP_REFERER

From: Date: Thu, 30 Dec 2004 00:37:11 +0000
Subject: #31340 [Opn->Bgs]: Notice: Undefined variable: HTTP_REFERER
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-71259@lists.php.net to get a copy of this message
ID: 31340 Updated by: sniper@php.net Reported By: jfishersmith at dialectsolutions dot com -Status: Open +Status: Bogus Bug Type: HTTP related Operating System: Windows 2000, NT PHP Version: 4.3.10 New Comment: In PHP 4.2.0, the 'register_globals' setting default changed to 'off'. See http://www.php.net/release_4_2_0.php for more info. We are sorry about the inconvenience, but this change was a necessary part of our efforts to make PHP scripting more secure and portable. Previous Comments: ------------------------------------------------------------------------ [2004-12-30 00:23:08] jfishersmith at dialectsolutions dot com Description: ------------ Since I installed PHP 4.3.10 and 5.0.3 the HTTP_REFERER produces the following error "Notice: Undefined variable: HTTP_REFERER in c:\inetpub\wwwroot\PHP\PHP_2party.php on line 444" The same code has worked successfully in previous versions of PHP. Is this something that should work still or has it been deprecated? Reproduce code: --------------- <? $againLink = $HTTP_REFERER; ?> <p><a href='<?=$againLink?>'>Another Transaction</a></p> Expected result: ---------------- The code should create a hyperlink back to the previous page. It is done in this manner as different HTML pages call this one transaction page. Actual result: -------------- The error indicated above is written to the screen and the hyperlink is not complete. For example the incomplete hyperlink is shown as: http://localhost/PHP/ instead of: http://localhost/PHP/PHP_2party_Order.html This means the browser does not return to the original location when the hperlink is clicked. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31340&edit=1

« previous php.bugs (#71259) next »