Re: syntax

From: Date: Wed, 27 Mar 2002 18:09:12 +0000
Subject: Re: syntax
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-90391@lists.php.net to get a copy of this message
Sorry I think I've badly explained this ! I'm getting results from mysql in a while loop but I need the results outside of the loops and so what I want to do is take the first variable from the db and rename it as variable 1 and then before the end of the while loop have a $i++; so i want $newvar_$i = result 1 $newvar_$i = result 2 so I can use them outside the loops as $newvar_1 and $newvar_2 hope that makes more sense ! > > > Can someone please remind me what the correct syntax for this is ! > in a loop > and want individual > > $ned_1_city = blah > $ned_2_city = blur > > I've been trying this but its wrong > > $ned_.$i._city = $ned_city ; > > thanks > john > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.general (#90391) next »