in reply to HTML Entities RegEx

Off of the top of my head; untested:

use HTML::Entities; use HTML::TokeParser::Simple; my $p = HTML::TokeParser::Simple->new('somefile'); while ( my $token = $p->get_token ) { print $token->as_is; next unless $token->is_start_tag( 'textarea' ); while ($token) { $token = $p->get_token; last if $token->is_end_tag( 'textarea' ); print HTML::Entities::_entities( $token ); } print $token->as_is; }

janitored by ybiC: Noted in title that this node isn't a duplicate of 356706.   Author confirms that *this* is the node to keep. This node subsequently unconsidered, so node title tweak removed.