Re: global var
| From: | Henk Jan Wils | Date: | Tue, 15 Mar 2005 18:59:56 +0000 |
| Subject: | Re: global var | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-38916@lists.php.net to get a copy of this message | ||
sorry, thats the way i meant it...
i have it that way, but it doesnt work...
----- Original Message ----- From: "Bastien Koert" <bastien_k@hotmail.com>
To: <double_u1@hotmail.com>; <php-db@lists.php.net>
Sent: Tuesday, March 15, 2005 7:50 PM
Subject: RE: [PHP-DB] global var
no, that is not how it should be <? $txt = "text"; function echo_txt() { global $txt; echo $txt; } ?>From: "H. J. Wils" <double_u1@hotmail.com> To: php-db@lists.php.net Subject: [PHP-DB] global var Date: Tue, 15 Mar 2005 18:38:13 +0000 Hi, I want to use a global var, but it doesnt seem to work. This how it should be right? <? $txt = "text"; function echo_txt() { global $txt; echo $global; } ?> but it doesnt work... -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php