Re: convert text to variable
| From: | Robin Vickery | Date: | Thu, 09 Nov 2000 15:39:12 +0000 |
| Subject: | Re: convert text to variable | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-24505@lists.php.net to get a copy of this message | ||
>>>>> "AT" == Alaiddin Tayeh <atayeh@p-i-s.com> writes:
> I have this code
> $size1=10;
> $size2=20;
> $size3=30;
> for($i=1;$i<4; $i++)
> {
print ${"size" . $i};
> echo"br"
> }
Although you should almost certainly be using an array instead...
--
Robin Vickery...............................................
Planet-Three, 3A West Point, Warple Way, London, W3 0RG, UK
Email: robin@planet-three.net Phone: +44 (0)870 729 5444