How can I replace some HTML tags based on their class in Perl?
Posted
by Victor Sanchez
on Stack Overflow
See other posts from Stack Overflow
or by Victor Sanchez
Published on 2010-05-11T19:17:59Z
Indexed on
2010/05/16
0:00 UTC
Read the original article
Hit count: 218
I need replace some tags in HTML using Perl:
I have this:
<span class="a">text</span><span class="a">text</span><span id="b">text</span>
I need this, where the span
tags with class=a
are changed to b
tags instead:
<b>text</b><b>text</b><span id="b">text</span>
I tried using HTML::Manipulator but did not succeed.
© Stack Overflow or respective owner