Re: [PHP] Self generating variables/arrays
- From: neuhauser@xxxxxxxxxx (Roman Neuhauser)
- Date: Sun, 26 Nov 2006 13:21:02 +0000
# jekillen@xxxxxxxxxxx / 2006-11-25 22:19:05 -0800:
Hello;
I am writing some code that will format results of a search for display.
I need to split an array into several different arrays but I won't know
before hand how many, so, I am looking for a way to dynamically
generate arrays for this purpose.
My present direction is to use the following code:
for($i = 0; $i < $c; $i++)
{ eval('$a_'.$i.' = array();'); }
what's wrong with:
for($i = 0; $i < $c; $i++)
{ $a[$i] = array(); }
--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man. You don't KNOW.
Cause you weren't THERE. http://bash.org/?255991
.
- References:
- Self generating variables/arrays
- From: jekillen
- Self generating variables/arrays
- Prev by Date: PHP sendmail proxy (using xinetd)
- Next by Date: Re: [PHP] Self generating variables/arrays
- Previous by thread: Re: [PHP] Self generating variables/arrays
- Next by thread: Re: [PHP] Self generating variables/arrays
- Index(es):
Relevant Pages
|
|