ID: 9699 Comment by: battyus4 at yahoo dot com Reported By: muffle at immortalcurse dot com Status: Closed Bug Type: HTTP related Operating System: Win 2000 PHP Version: 4.0.4pl1 New Comment:
Until the bug is fixed this works: echo <<<EOD <script language="javascript"><!-- location.replace("index.php#1"); --></script> EOD; die; Previous Comments: ------------------------------------------------------------------------ [2001-03-16 17:26:49] [EMAIL PROTECTED] Can't reproduce. Try latest CVS build from http://www.php4win.de/ --Jani ------------------------------------------------------------------------ [2001-03-12 06:12:15] muffle at immortalcurse dot com This bug affects how variables are parsed from the URL, in instances when the header() function is used to forward the browser. Eg. if the following code was used in a script: header("Location: index.php?variable=blah") Then index.php would be parsed and PHP would assign $variable == blah. However, if the user adds a HTML anchor reference onto the end, eg: header("Location: index.php?variable=blah#1") Then the web browser would still parse it fine, but PHP will assign $variable == blah#1. If the user refreshes the browser window (eg., the location header isn't being used to laod the script) then it works fine, so this bug is limtied to the header() function only. Fix: The script writer can add an & before the # character in the URL, eg: index.html?variable=blah ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=9699&edit=1