perl.beginners
[Top] [All Lists]

dereferencing hashes

Subject: dereferencing hashes
From: godsrock37@xxxxxxxxx (Hunter Barrington)
Date: Wed, 29 Aug 2007 14:57:03 -0400
Newsgroups: perl.beginners


ok so im using HTML::TreeBuilder to pull some data off of a website and parse it. If I'm understanding this right each tag of the tree is put inside the tree as a hash reference with hash references inside of it for each tag thats below it. Like:
<html><body><p> = $root_hash_ref->$body_hash_ref->$p_hash_ref

regardless if i understand the module or not, how do i dereference the data i need? in other words, i need to be able to pull data out of the hashes (i know where its kept) without iterating over it. i tried my $piece = ${row}{3} where 3 would be they key number and that didnt work. perlref was only so helpful and i only got some of the basics. any thoughts?

<Prev in Thread] Current Thread [Next in Thread>