RE: [PHP] Variable dynamique
| From: | PHPBeginner.com | Date: | Mon, 12 Mar 2001 16:49:07 +0000 |
| Subject: | RE: [PHP] Variable dynamique | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-43496@lists.php.net to get a copy of this message | ||
do this:
${$var.$num}
But, as I can only guess you are not very familiar with arrays, they usually
better for most of your needs.
I think this is what you have to learn instead.
www.php.net/arrays
Sincerely,
Maxim Maletsky
Founder, Chief Developer
PHPBeginner.com (Where PHP Begins)
maxim@phpbeginner.com
www.phpbeginner.com
-----Original Message-----
From: Pierre-Yves Lemaire [mailto:pylem@sympatico.ca]
Sent: Monday, March 12, 2001 12:58 AM
To: php-general@lists.php.net
Subject: [PHP] Variable dynamique
I receive 2 variables, $var and $num
I need to make a variable out of these two like this
$var2 where $num = 2 or
$var3 where $num = 3
How can I do that ?
__________________
Pierre-Yves Lemaire
514.729.8100