title: open window and run function on that window
body: <p>I'd like to open a new window, this window has a list of objects, and these objects should be filtered based on a selection from the previous window. I figured I can filter the list through a function, but how do I run said function?</p>
  
  <p>This is what I am able to do:</p>
  
  <pre><code>var popup = window.open('pageURL');
      $(popup.document).ready(function() {
          // this is where function should be
          popup.alert('HelloWorld');
      });
  </code></pre>
  
  <p>But how do I change the alert to a function? </p>
  
  <p>If I have a function <strong>on my other app</strong> , <code>function test() { alert('HelloWorld'};</code>
  How do I run this function from my first app? </p>
  
  <p>Swapping <code>popup.alert('HelloWorld');</code> with <code>popup.test();</code> did not work.</p>