W3C home > Mailing lists > Public > www-dom@w3.org > January to March 2002

Using addEventListener to call function when document loads

From: Jonathan Watt <0jaw@qlink.queensu.ca>
Date: Tue, 19 Mar 2002 20:44:51 -0500
Message-ID: <3C97E993.6090807@qlink.queensu.ca>
To: www-dom@w3.org
I have asked this question before, but for whatever reason I didn't get 
an answer. I am going to ask it again as I think that it is important. 
Apologies to anyone who doesn't want to be bothered by it.

How can you use addEventListener in a document to call a function when 
the same document loads? If I understand the recommendations correctly 
then adding onload attributes to tags is only still supported for 
backwards compatibility. But I don't see any way of using 
addEventListener to recreate the same action. Is this something that was 
overlooked during the writing of the recommendations? Or am I myself 
overlooking something?


Received on Tuesday, 19 March 2002 20:41:32 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 October 2015 10:46:09 UTC