
novicemonkey
Novice
Mar 29, 2004, 12:43 AM
Post #1 of 2
(291 views)
|
|
access array of hashes
|
Can't Post
|
|
I have a for each statement whic loops round and insert loads of hashes into an array like this: foreach(){ my %entry = (href => $href, text => $label, bold => $bold); push @output, \%entry; } $data = @output; foreach my $l (@{ $data }) { ......... } In the second for each how would i test to see if the first has contained an text value = "james"? I have tried loads of combinations for accessing hashes in arrays like $l->{text} but nothing ?
|