The script below works fine for me. Do you have track_vars set to "On"? I'm not 100% sure it's related, but it might be since I don't have any problem with your sample script.
Cheers, Rob. On Wed, 2003-08-13 at 10:26, Shawn McKenzie wrote: > I'm having problems using global vars. I have read the docs and all of the > notes but it's not helping. Simplified example: > > /dir1/script2.php > <?php > $test = array ( 'a' => '1', 'b' => '2'); > ?> > > /dir1/script1.php > <?php > include("/dir1/script2.php"); > print_r($test); //works great > print_r($GLOBALS['test']); //does not work > ?> > > This is a local include so the vars should be in the global scope right? > Any help please? > > TIA > -Shawn -- .---------------------------------------------. | Worlds of Carnage - http://www.wocmud.org | :---------------------------------------------: | Come visit a world of myth and legend where | | fantastical creatures come to life and the | | stuff of nightmares grasp for your soul. | `---------------------------------------------' -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php