You are here: Re: what is the meaning « PHP Programming Language « IT news, forums, messages
Re: what is the meaning

Posted by Thomas Mlynarczyk on 11/29/06 14:37

Also sprach Jerry Stuckle:

> $GLOBALS['notDefinedYet'] = $x;
> will not give a notice.
> $x = $GLOBALS['notDefinedYet'];
> will. See the difference?

Yes, of that I was aware.

> global($notDefinedYet);
> Doesn't actually use the value. It just declares it to be global.

I thought

global $myVar;

was the equivalent of

if ( !isSet( $GLOBALS['myVar'] ) )
{
$GLOBALS['myVar'] = null;
}

$myVar = &$GLOBALS['myVar'];

Greetings,
Thomas

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация