[prev in list] [next in list] [prev in thread] [next in thread]
List: php-general
Subject: Re: [PHP3] Associative arrays on the fly
From: Colin Viebrock <cmv () privateworld ! com>
Date: 1998-05-29 14:47:50
[Download RAW message or body]
Also sprach Michael Brennen (at 06:24 PM 5/28/98 -0500) ...
>I think the line $partcrc[]=array("$tmpseq"=>"$tmpcrc") is inserting
>a new one entry *array* in the next slot of $partcrc, not an
>associative key and data, so I'm ending up with a multi dimensional
>array (right?).
Right.
>Is there a way to make this insert a key/data into the
>same array? I'm sure I will kick myself at how easily I overlooked it
>when I find out how it works.
Polish your boots: :)
$i=0;
while ( $i<$nnumprods ) {
// ... build two strings $tmpseq and $tmpcrc with the key and data
$partcrc[$tmpseq]=$tmpcrc;
}
.........................................................................
Colin Viebrock Creative Director - Private World Communciations
cmv@privateworld.com 331 - 67 Mowat Avenue
http://www.privateworld.com Toronto, Ontario, CANADA, M6K 3E3
ICQ: 11386088
How stupid can people be? Answer:
ftp://ftp.cs.uoregon.edu/pub/hacks/whale/whale.qt
(warning: 11 megs)
--
PHP 3 Mailing List http://www.php.net/
To unsubscribe send an empty message to php3-unsubscribe@lists.php.net
To subscribe to the digest list: php3-digest-subscribe@lists.php.net
For help: php3-help@lists.php.net Archive: http://www.tryc.on.ca/php3.html
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic