You can render HTML using document.write()
document.write('<html><body><h2>HTML</h2></body></html>')
But to append existing HTML string, you need to get the id of the node/tag under which you want to insert your HTML string.
There are two ways by which you can possibly achieve this:
- Using DOM -
var tag_id = document.getElementById('tagid');
var
…
Top comments (0)