onload event generation, incompatible with DOM3