Re: dynamically naming PHP vars on the fly?
| From: | Govinda | Date: | Thu, 06 Aug 2009 00:01:24 +0000 |
| Subject: | Re: dynamically naming PHP vars on the fly? | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-296362@lists.php.net to get a copy of this message | ||
You can use variable variables ... You can make more complicated statements with this technique. $var1 = 'apple'; ${ 'Fruit_' . $var1 } = 'organic'; echo $Fruit_apple; // here you arethank you all 3, for your help! That was just what I wanted! -Govinda