Use insertAdjacentHTML
which is supported in all current browsers:
div.insertAdjacentHTML( 'beforeend', str );
The position parameter beforeend
will add inside the element, after its last child.
Live demo:http://jsfiddle.net/euQ5n/
Use insertAdjacentHTML
which is supported in all current browsers:
div.insertAdjacentHTML( 'beforeend', str );
The position parameter beforeend
will add inside the element, after its last child.
Live demo:http://jsfiddle.net/euQ5n/