%children is an associative array (hash/struct) dereferenced using the syntax 
$children{key}.

%line is also an associative array.

$children{key}'s value is an array.

In CF, %children is a struct that contains arrays for the value at each key.

That is,
<cfset children["my_key"]=ArrayNew(1)>
<cfset arrayAppend(children["my_key"],my_value)>

HTH
Ryan

-----Original Message-----
From: Cedric Villat [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 16, 2003 11:46 PM
To: CF-Talk
Subject: OT: Perl


Ok, sort of off topic, but I'm trying to convert a perl program to CF. I'm
stuck on a line and have no idea what it's equivalent is in CF. The line is:

push @{ $children{$line{"p1"}}}, shortname($line{"node"});

I assume $children is an array, and $line is a single line of an input file.
What exactly does the $children{$line{"p1"}} mean? How are they indexing an
array based on a string? Any ideas?

Cedric



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/lists.cfm?link=t:4
Subscription: http://www.houseoffusion.com/lists.cfm?link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. 
http://www.fusionauthority.com/ads.cfm

Reply via email to