Personally I was just using print debugging. I started by getting
I printed out the value of $ts, which was an array, but was not blessed to a package. Since it had no package associated with it (when printing, HASH(0x864497c) is not blessed, HTML::TableExtract=HASH(0x864497c) is) that means you cannot call methods on it. So then I did print "@$ts\n"; and saw it was full of array refs. At this point you could loop through the array and print the results or do a print "@{$ts->[0]}\n";. Of course... the much better way to do this is use Data::Dumper and do a print Dumper($ts),"\n"; which would give youCan't call method "coords" on unblessed reference at test.pl line 32.
Which shows the whole structure obviously.... quick and dirty debugging can often help you find out what is up, or you could always actually use the debugger, which I am usually too lazy to do :)$VAR1 = [ [ 'DHL Next Day 10:30 am (Letter – 150 Pounds)', 'Tuesday, Jan 10, 2006 By 10:30 A.M.', '1' ], [ 'DHL Next Day 12:00 pm (Letter – 150 Pounds)', 'Tuesday, Jan 10, 2006 By Noon', '1' ], [ 'DHL Next Day 3:00 pm (Letter – 150 Pounds)', 'Tuesday, Jan 10, 2006 By 3:00 P.M.', '1' ], [ 'DHL 2nd Day Service (Letter – 150 Pounds)', 'Wednesday, Jan 11, 2006 By 5:00 P.M.', '2' ], [ 'DHL Ground Service (Letter – 150 Pounds)', 'Tuesday, Jan 10, 2006 By end of day', '1' ] ];
Hopefully this helps even more than the first message.
Any questions?
In reply to Re^2: Problems with TableExtract
by suaveant
in thread Problems with TableExtract
by bcdeery
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |