I am trying to remove a node from a dom tree using javascript while preserving it. I tested the three approaches shown below and they work fine in Firefox, but not in IE 8 (see Example below).
function removeNodeKeepChildren(node){
Node input example:
<span class="A1"> start text <span class="F"> bold text </span> end text </span>
what this should result in:
start text <span class="F"> bold text </span> end text
What IE 8 does:
start text <span class="F"> </span> end text
As you can see, IE ignores / removes nested children.
I would be grateful for any help :)
sotix source share