G
Giacomo
I obtained all the html code contained in a div by:
var all = getElementsByClassName('div','twikiTopic');
var result = all[0].innerHTML;
let's say that the code contained in "result" has this structure:
A
<div id="pippo">
B
</div>
C
when A,B and C is arbitrary html code. Using the function replace
(javascript) I'd like to remove all the code inside and following the
div with id="pippo", obtaining:
A
<div id="pippo">
</div>
Thanks in advance, bye.
Giacomo
var all = getElementsByClassName('div','twikiTopic');
var result = all[0].innerHTML;
let's say that the code contained in "result" has this structure:
A
<div id="pippo">
B
</div>
C
when A,B and C is arbitrary html code. Using the function replace
(javascript) I'd like to remove all the code inside and following the
div with id="pippo", obtaining:
A
<div id="pippo">
</div>
Thanks in advance, bye.
Giacomo