title: Where to put my $(document).ready(function(){ When I have methods in a .js
body: <p>I created a somefile.js where somefile.js contains some jQuery method.  So for instance it contains this function:</p>
  
  <pre><code>function showWindow(divID)
  {
      var dialogDiv = $(divID);
  
      dialogDiv.dialog
      (
          {
              bgiframe: true,
              modal: true,
              autoOpen: false,
              show: 'blind'
          }
      )
  
      dialogDiv.dialog("open");
  }
  </code></pre>
  
  <p>So in my .aspx page (or whatever, it could be an .html), I have a button:</p>
  
  <pre><code>&lt;input type="button" onclick="showPopUp('testDiv')" value="Click Me!" /&gt;
  </code></pre>
  
  <p>My question is, we're going to use showPopUp all over in our app.  If it's called from an onClick event, then where do I put my  $(document).ready(function() since this code is not in the page, but in a .js file?</p>