Using JavaScript in onload

Sometimes, it makes sense to wait until all the texts, images, sounds and videos are uploaded to a website before trying to run scripts. For example, the script commands in the BODY section, which will be implemented as they are, could fail if they relate to the elements on the page has not yet been charged. The JavaScript onload event was “fired” or “on” when the page loads completed and ready for processing. Script run based on the onload event, therefore, can safely assume that the page is all .

onload in the use of JavaScript

write a function that you want that runs only when the page is fully loaded. Suppose that is called GO .

Add the following attribute to the BODY tag: onload = “GO ()”

Specify the onload handler in the script if more convenient, by placing the following statement JavaScript on the website of the HEAD section: document.body.onLoad = GO

Featured Links:

Google Payload
Proven Money Maker At $9,547 A Day.
Burn The Fat Feed The Muscle
Burn The Fat - Top Selling Fat Loss Ebook Since 2003.
Save My Marriage Today!
Have You Ever Stayed Awake at Night Stressing About Whether or Not Your Marriage Will Last ... And What You Can Possibly Do to Save It?
Ultra Hot* SpywareBot: #1 AntiSpyware
Scan your computer for hidden AdWare and Spyware, Remove them permanently.
Top Movie Downloads
Join the Internet revolution and start downloading free movies and more!
Get Google Pay-Per-Click Ads Free!
Internet Marketer Gets $87 Million in Google Pay-Per-Click Ads FREE! ... And Makes Over $314 Million as a Result! ...And Now He's Going to Give You This Same Secret for Next to Nothing!
Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • bodytext
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • StumbleUpon
  • TwitThis

Leave a comment

You must be logged in to post a comment.