/usr/share/doc/perl-HTML-Parser/eg
NameSizeModeActions
hanchors11960644editdlrm
hbody7290644editdlrm
hdisable7400644editdlrm
hdump7080644editdlrm
hform25020644editdlrm
hlc7170644editdlrm
hrefsub30680644editdlrm
hstrip17670644editdlrm
htext6120644editdlrm
htextsub9360644editdlrm
htitle4610644editdlrm
Edit: /usr/share/doc/perl-HTML-Parser/eg/htitle (461B)
#!/usr/bin/perl # This program will print out the title of an HTML document. use strict; use warnings; use HTML::Parser (); sub title_handler { my $self = shift; $self->handler(text => sub { print @_ }, "dtext"); $self->handler(end => "eof", "self"); } my $p = HTML::Parser->new( api_version => 3, start_h => [\&title_handler, "self"], report_tags => ['title'], ); $p->parse_file(shift || die) || die $!; print "\n";