Page 1 of 1

Question about the "On Load" attribute

Posted: Fri Feb 18, 2011 7:37 am
by complete
Is "On Load" or "OnLoad" an attrubute of the <html> tag or the <body> tag? I want to run a javascript function when my web page loads.

Re: Question about the "On Load" attribute

Posted: Fri Feb 18, 2011 3:45 pm
by Jonah Bron
The <body> tag.

Re: Question about the "On Load" attribute

Posted: Fri Feb 18, 2011 8:38 pm
by s.dot
"onload" can be used on body, img, and frames I believe.
I haven't used it in so long.