JS. How to replace html element with another element/text, represented in string?
- by EL 2002
I have a problem with replacing html elements.
For example, there is a table
<table><tr><td id="idTABLE">0</td><td>END</td></tr></table>
(it can be div, span, anything)
And string in JS script
var str='<td>1</td><td>2</td>';
(it can be anything, '123 text', '<span123…