Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

Re^2: Problems with TableExtract

by suaveant (Parson)
on Jan 10, 2006 at 05:53 UTC ( #522099=note: print w/replies, xml ) Need Help??

in reply to Re: Problems with TableExtract
in thread Problems with TableExtract

Cool module :)

I looked at my version and I have 1.08, for simplicity I had just gone with the debian version, I guess its a bit behind.

I wonder if he did the same as me, has an older version but was looking at the docs on :)

                - Ant
                - Some of my best work - (1 2 3)

Replies are listed 'Best First'.
Re^3: Problems with TableExtract
by mojotoad (Monsignor) on Jan 10, 2006 at 06:32 UTC
    With 1.08, try this:
    my $te = HTML::TableExtract->new( headers => [qw($service $arrival $tr +ansit)] ); $te->parse($html_string); my $ts = $te->first_table_state_found; foreach my $row ($ts->rows) { foreach my $cell (@$row) { print $cell; } }

    If it's actually capturing tables, that should work. (you can monitor, in detail, whether tables are being captured by setting the 'debug' parameter to varying levels (1..7) in the new() constructor).

    Let me know what happens,

Re^3: Problems with TableExtract
by mojotoad (Monsignor) on Jan 10, 2006 at 06:36 UTC
    And yes, part of this is my fault. As I phased out the array-only functionality (i.e. the tables() method) I eventually aliased that to the table_states() method and it has caused confusion. I should have waited longer before ressurecting the tables() method, if at all. (in my defense, it is what I would have called the table_states() method to begin with, but in a very very early version of the module I used tables() to return the arrays. Ah well.)


Log In?

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

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (7)
As of 2020-08-11 01:38 GMT
Find Nodes?
    Voting Booth?
    Which rocket would you take to Mars?

    Results (58 votes). Check out past polls.