start tags with no end tags. s/
\s+(
\s*<\/p>//gis; $_; } # ------------------------------------------------------------------------- sub html_to_plain { my ($self, $contobj, $txt) = @_; # keep it (very) simple $txt =~ s/
/\n/gis; $txt =~ s/<[^>]+>//gs; $txt; } # ------------------------------------------------------------------------- sub html_to_xml { my ($self, $contobj, $txt) = @_; return $txt; # super simple } # ------------------------------------------------------------------------- sub xml_to_html { my ($self, $contobj, $txt) = @_; return $txt; # super simple } # ------------------------------------------------------------------------- sub mshtml_to_html { my ($self, $contobj, $txt) = @_; eval { require HTML::WebMake::MSHTMLtoHTML; $txt = HTML::WebMake::MSHTMLtoHTML::convert ($self, $contobj, $txt); }; if ($@) { die "failed to convert mshtml_to_html: $@"; } return $txt; } # ------------------------------------------------------------------------- sub format_is_binary { # static my ($fmt) = @_; if (!defined $fmt) { carp "undef arg in format_is_binary"; } return 0 if ($fmt =~ m,^text/,); return 0 if ($fmt =~ m,^application/xml,); return 1; # default } # ------------------------------------------------------------------------- 1;