htmlText.replace(/<(\/?)p([^>]*)>/gi, "<$1span$2>");
Replace character inside the htmlText
-
14-04-2022 - |
Pregunta
I have a htmlText with this normal content:
<TEXTFORMAT LEADING="2"><P ALIGN="LEFT"><FONT>...</FONT></P></TEXTFORMAT>
And user can customize my textFeild, so it would happen to have many <p>
tags, inside this htmlText... How can I replace all these <p>
tags to <span>
?
Thanks in advance :)
Solución
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow