in reply to Re^4: How to output the words that you want that came thru an html file?
in thread How to output the words that you want that came thru an html file?

This works for me. :-) A few too many blank lines in the output perhaps.

use Modern::Perl; use HTML::HTML5::ToText; use Web::Magic -quotelike => 'web'; my $converter = HTML::HTML5::ToText->with_traits(qw/ShowLinks/)->new; web <http://www.gamezebo.com/games/marvel-avengers-alliance/walkthroug +h> -> assert_success -> querySelectorAll('div.walkthrough_section') -> foreach(sub { print $converter->process($_); })

Disclaimer: I'm the author of both HTML::HTML5::ToText and Web::Magic.

perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'
  • Comment on Re^5: How to output the words that you want that came thru an html file?
  • Download Code