jdlev has asked for the wisdom of the Perl Monks concerning the following question:
Here is what I understand about the TreeBuilder Function, please correct me in any areas that I am wrong:
use HTML::TreeBuilder; This calls the "submodule" from the perl library for use in our code.
$myobject = HTML::TreeBuilder->new; Creates a new object for the treebuilder to build upon. This may sound dumb, can someone please explain what an "object" is? Also, what does this "->" tell the computer program to do?
$myobject->parse_file($my-file-to-pull-info-from); This fills the tree with the content based on html tags?
@a-new-array = $myobject->look_down(....); And this is the main area of confusion for me. I don't know how to tell the look_down function what to look for when searching tables, or how to locate specific information. An indepth look at the look_down function would be very helpful and greatly appreciated! Also, if I messed up any of the other items in my description of how to use HTML::TreeBuilder, please feel free to correct my mistakes.
Thanks for any help!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: HTML::TreeBuilder - Look_Down Function
by Tanktalus (Canon) on Dec 23, 2008 at 05:17 UTC | |
by jdlev (Scribe) on Dec 23, 2008 at 16:56 UTC | |
|
Re: HTML::TreeBuilder - Look_Down Function
by wfsp (Abbot) on Dec 23, 2008 at 07:41 UTC | |
|
Re: HTML::TreeBuilder - Look_Down Function
by toolic (Bishop) on Dec 23, 2008 at 13:57 UTC |