/usr/share/doc/libhtml-parser-perl/examples
NameSizeModeActions
hanchors11960755editdlrm
hbody7290755editdlrm
hdisable7400755editdlrm
hdump7080755editdlrm
hform25020755editdlrm
hlc7170755editdlrm
hrefsub30680755editdlrm
hstrip17670755editdlrm
htext6120755editdlrm
htextsub9360755editdlrm
htitle4610755editdlrm
Edit: /usr/share/doc/libhtml-parser-perl/examples/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";