Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: HTML::TokeParser Frustration

by Anonymous Monk
on Oct 17, 2008 at 03:43 UTC ( [id://717647]=note: print w/replies, xml ) Need Help??


in reply to HTML::TokeParser Frustration

get_trimmed_text (like get_text) returns text as documented, not markup. Try sticking with get_tag .

Replies are listed 'Best First'.
Re^2: HTML::TokeParser Frustration
by Anonymous Monk on Oct 17, 2008 at 04:07 UTC
    Changing to get_tag yields...

    Found Data: ARRAY(0x81e326c)

      Instead of this:
      print "Found Data: $text\n";
      try this:
      use Data::Dumper qw/Dumper/; ... print Dumper( $text );
      As explained in the manual for HTML::TokeParser, the "get_tag" function returns a reference to an array, and Dumper is just an easy way to see what the array elements contain.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://717647]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (8)
As of 2024-04-18 12:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found