[Javascript] Handle several window.onload functions

Guillaume javascript at webdesignofficina.com
Tue Jul 5 15:22:21 CDT 2005


Hi list,

This is my first post here so let me introduce myself briefly: my name 
is Guillaume and i'm working as a freelance webdesigner
in Paris, France.
 I was told elsewhere, the css-d mailing list, by a very nice guy, Roger 
Roelofs, who helped me a lot on some JavaScript issues, that this was a 
great list to ask for help. I've been using JS since the very begining 
of my activity on the web but my skills are limited to change scripts 
that are already built, not to build them from the scratch.
So here i go:  I focused a lot this last year on Css and Accessibility. 
I recently discovered the concept of "Unobtrusive Javascript" and try 
now to separate completely the JS i use from the document content. The 
problem i encounter is that i use several window.onload for the same 
document, wich cancel each other called separately. I'd like to build a 
global window.onload function, in wich i could add a list of different 
functions I fire up with window.onload.
I actually thought this would be easy... Apparently not when i read 
Simon Willison's weblog about this subject in an article called 
"Executing JavaScript on page load" 
<http://simon.incutio.com/archive/2004/05/26/addLoadEvent>
I'm unable, don't have the skills, to choose carefully for a valid 
method when i read this article and the multiple comments related.
So can this problem be solved by a simple way, cross-browser, robust 
method ?
Could someone point me to a simple ressource, or help me on this problem ?
Thanks.
Guillaume
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.evolt.org/pipermail/javascript/attachments/20050705/f1cb4898/attachment.htm>


More information about the Javascript mailing list