Welcome to WebmasterWorld Guest from 188.8.131.52
Forum Moderators: open
If it must be done prior to page onload use write() after onload use getElementById or similar.
With practice of putting js at end of body (or even higher), is waiting for onload obsolete ?
assets like images might not be fully loaded yet