develooper Front page | perl.libwww | Postings from October 2001

SV: HTML::Parser question

October 30, 2001 04:41
SV: HTML::Parser question
Message ID:
HTML::Parser->new(text_h => [sub {$buf .= shift },
'dtext'])->parse($content) || die $!;

/Jonas Nordström

-----Ursprungligt meddelande-----
Från: ADJE WebMail Technical Support Team []
Skickat: den 30 oktober 2001 05:00
Ämne: HTML::Parser question

Question: How do I extract the plain text from an HTML file, or, put
another way, how do I remove the html markups, just leaving the plain
text?  I have looked at the example provided in HTML::Parser, in


which comes close to what I need, however, I would like to store the
plain text in a variable, as opposed to having it to STDOUT (standard
output).... any ideas??

ADJE WebMail Technical Support

-->> FREE Perl CGI scripts add WEB ACCESS to your
-->> POP E-Mail accounts! Download today!! Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About