Discussion:
Removing HTML tags: is there a Perl-equivalent to PHP 'strip_tags'?
(too old to reply)
Francesco Moi
2004-05-31 14:28:47 UTC
Permalink
Hi.

I've got some HTML texts, but I want to remove HTML tags from it.
I mean, convert '<b>foo</b>' into 'foo'.

In PHP you can use 'strip_tags':
http://www.php.net/strip_tags

Is there any Perl-equivalent?

Thanks.
Bill
2004-05-31 17:34:35 UTC
Permalink
Post by Francesco Moi
Hi.
I've got some HTML texts, but I want to remove HTML tags from it.
I mean, convert '<b>foo</b>' into 'foo'.
http://www.php.net/strip_tags
Is there any Perl-equivalent?
Thanks.
Why not google for it first?

http://groups.google.com/groups?q=perl+strip_tags&hl=en&lr=&ie=UTF-8&selm=92d64088.0309241735.7a05269c%40posting.google.com&rnum=3
Gunnar Hjalmarsson
2004-05-31 18:05:04 UTC
Permalink
Post by Bill
Post by Francesco Moi
I've got some HTML texts, but I want to remove HTML tags from it.
I mean, convert '<b>foo</b>' into 'foo'.
http://www.php.net/strip_tags
Is there any Perl-equivalent?
Why not google for it first?
http://groups.google.com/groups?q=perl+strip_tags&hl=en&lr=&ie=UTF-8&selm=92d64088.0309241735.7a05269c%40posting.google.com&rnum=3
Or check out the Perl FAQ:

perldoc -q "remove HTML"
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
Loading...