iframe - Javascript Execute After Page Render IE6 -


Page 6 Completely in IE 6 , But just for IE 6 testing now. Firefox looks OK). I can get around this by calling JS at window.onload :

  window.onload = function () {doIt ();}  

However, my concern is that I can overwrite anything else which may already be in window.onload . The code will be used as part of the library so that I can not guarantee that window.onload will not be set elsewhere by any other person. I will add the onload event to my function like this:

  window.onload + = function () {doIt1 ();} window.onload + = function } {DoIt2 ();}  

But when I do this, then only called doit2 () when the page is sung completely, then Is there a way to register an event handler? My second thought was to just put my code in a loop check to ensure that all the items are present before running. But I am scared that it might possibly lock the browser.

For just some background information, my code is showing / showing IFrame / I know that I can use the IFrame's Ols attribute, but call me Fully loaded iFrames are required before

Any thoughts from the community? Thank you in advance for your input.

Use this normal addLoadEvent function ...

  function AddLoadEvent (func) {if (typeof window.onload! = 'Function') window.onload = func; Else {var oldLoad = window.onload; Window.onload = function () {if (oldLoad) oldLoad (); Ceremony (); }}}  

This mandatory queues to perform the task. This does not overwrite the previously assigned handler. Sample usage below ...

addLoadEvent (function () {warning ("one!");}); AddLoadEvent (two); Function two () {alert ("two!"); }

I think that you want to mention the libraries as if you take care of such known issues.


Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -