|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2003-01-24 16:09 UTC] moriyoshi@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Dec 06 05:00:02 2025 UTC |
A BIG ATTENTION! let`s say that we have this 2 files include.php & test.php: include.php <? $foo="blabla"; ?> and now test.php: <? require "include.php"; function do_test() { if ($foo) {echo "foo is set if called from function<br>";} else {echo "bang foo is not set if called from function<br>";} } do_test(); if ($foo) {echo "foo is set if called from main<br>";} else {echo "bang foo is not set if called from main<br>";} Result of the program is: bang foo is not set if called from function. foo is set if called from main Bug? Server: Apache/1.3.26 (Win32) PHP/4.2.3