HTML::TokeParser#

Alternative HTML::Parser interface

SYNOPSIS#

require HTML::TokeParser;
$p = HTML::TokeParser->new("index.html") ||
     die "Can't open: $!";
$p->empty_element_tags(1);  # configure its behaviour

while (my $token = $p->get_token) {
    #...
}

DESCRIPTION#

The HTML::TokeParser is an alternative interface to the HTML::Parser class. It is an HTML::PullParser subclass with a predeclared set of token types. If you wish the tokens to be reported differently you probably want to use the HTML::PullParser directly.

The following methods are available: