views:

23

answers:

2

If I open a window via

mywin = window.open(...);

Is there a way I can be notified when mywin has loaded? I mean the opener be notified?

A: 

This should work.

$(document).ready(function(){ 
   // Do something
}); 
kyndigs
This only tells me when the current window has loaded NOT when a separate window has loaded.
John Isaacks
+1  A: 

I think onload event is what you are looking for:

mywin.onload = function(){
  alert('The window has loaded');
};
Sarfraz
Ahh I didn't realize I could use that on a window like that! Thanks
John Isaacks