title: How to get child window url from parent window using javascript
body: <p><br>
      I'm launching a child window with a window reference name. I want to capture the URL of the child window when it changes each time.</p>
  
  <pre><code>    var winRef;
      var url='http://www.google.com';
      if(winRef == null || winRef.closed) 
      { 
        winRef = window.open(url, "mywindow");
        winRef.focus();
        alert(winRef.location.href); 
      }
      winRef.captureEvents(Event.CHANGE);  
      winRef.onchange=function(){
        alert('change event triggered');
        console.log(winRef.location.href);
      }
  </code></pre>
  
  <p><br>I have tried with events LOAD, CHANGE to capture the location change of the window. But the LOAD and CHANGE events gets triggered only once. <br><br>I dont want to use setinterval to check for the change in window.location.href as it may lead to performace issues.<br><br>
  Is there any other way around to get the child window URL?</p>