|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2000-11-09 01:42 UTC] brozen at torah dot org
Please take a look at this: (php3) http://zeraim.torah.org/~cblack/testdir/index.php3 http://zeraim.torah.org/~cblack/testdir/index.php3?sid=3 Now, try these: (php4) http://terumah.teamgenesis.com/~cblack/index.php3 http://terumah.teamgenesis.com/~cblack/index.php3?sid=2 Precisely the same code. PHP on zeraim incorporates the header & footer and then parses all as one, while on terumah it is attempting to parse the header & footer as if they were independent of the file into which they are included. Or in other words, PHP3 used to incorporate a 'require()ed' file without doing any work on it, and then parsed the whole thing together. So you could have an IF statement in the header [ if (...) { ] that ended in the footer [ } ]. No longer! That's why the same code is generating parse errors. PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Dec 19 23:00:01 2025 UTC |
index.php3: <? require "header.php3"; ?> sid is set <? require "footer.php3"; ?> header.php3: <? if (isset($sid)) { ?> footer.php3: <? } else { echo "sid not set"; } ?>