in reply to Overriding via a subclass?
use HTML::Parser; my $parser = HTML::Parser::->new(api_version => 3); $parser->handler(text => sub { print "This is the text: $_[0]" }, "text"); $parser->parse($html_to_parse);
Subclassing can still be done, but there's rarely a reason to do it. This way is much more flexible.
-dlc
|
|---|