June 2007 Archives

Archive navigation
Home

Managing multiple onLoad events with Prototype

Jun 16

This is an update to a previous article written way back in 2003 "Managing multiple onLoad events in JavaScript".

The article describes how to create an array of onload (window.onload) events in order to queue each event and enable the browser to perform onload sequentially. However this can all be forgotten in preference to the Prototype Javascript Framework and the useful Event Observe method.

Use Event.observe instead of using <body onload="return myFunction()"> or DOM Level-0 event property window.onload = myFunction;


Continue reading
Filed under:
Scripting