|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2003-08-20 06:01 UTC] i dot spalletti at iast dot it
Description:
------------
As of documentazion if you pile up two header('Location: URL)'; the second URL will be opened.
In 4.3.3RC4 you will load the first one
Reproduce code:
---------------
<?php
header('Location: http://www.php.net');
print "Let's write something interesting that nobody would read";
header('Location: http://qa.php.net');
?>
Expected result:
----------------
You should load PHP home page
Actual result:
--------------
You will load QA home page
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Nov 06 10:00:01 2025 UTC |
You should partially modify my report <?php header('Location: http://www.php.net'); print "Let's write something interesting that nobody would read"; header('Location: http://qa.php.net'); ?> Will load the first URL <?php header('Location: http://www.php.net'); header('Location: http://qa.php.net'); ?> Will load the second URL (note the absence of any print statement). I.e. if you output something the first URL is to be loaded, otherwise you'll load the second one