- - Code, Content, and Presentation
- ---- document.getElementById vs document.write?
Fotiman - 12:24 am on Nov 15, 2012 (gmt 0)
What is safe?
Any DOM element that was defined prior to the script.
What is not safe?
Any DOM element that was defined after the script (or elements that are being loaded asynchronously, which, for the record, are also not safe with the document onload event).
Brought to you by WebmasterWorld: http://www.webmasterworld.com