Justtechjobs.com Find a programming school near you






Online Campus Both


php3-list | 199807

[PHP3] $GLOBAL["variable"] as defaultvalue From: Marcus Johansson (marrasmarras <email protected>)
Date: 07/20/98

Hi!

How come this will not work:

function MyFunc($defv=$GLOBAL["variabel"])
{
 ...
}

This generates a PARSE ERROR...

While:

function MyFunc($defv=1)
{
 if ($defv==1) $defv=$GLOBAL["variabel"];
}

works fine!

Have I done something wrong?

---
Marcus

______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com

-- PHP 3 Mailing List http://www.php.net/ To unsubscribe send an empty message to php3-unsubscribe <email protected> To subscribe to the digest list: php3-digest-subscribe <email protected> For help: php3-help <email protected> Archive: http://www.php.net/mailsearch.php3