Under certain circumstances, document.write can overwrite the entire page, since . This is because this function is only called after the page has been completely loaded. You can find more information about this here.
...
Code Block |
---|
document.getElementById(…).innerHtml = … |
...