I am on Windows, so I can not fully verify this, but you can adapt the htext that comes with HTML :: Parser :
#!/usr/bin/perl use strict; use warnings; use HTML::Parser; use Term::ANSIColor; use HTML::Parser 3.00 (); my %inside; sub tag { my($tag, $num) = @_; $inside{$tag} += $num; print " ";
source share