use strict; use HTML::ProceduralMarkupRemover; html_passes_rules($some_html, \%html_rules) or die "Ack! I can't cope!"; my $clean_html = apply_html_rules($come_html, \%html_rules);