title: Detect the completion of js script files present at bottom
body: <p>The following link <a href="http://developer.yahoo.com/performance/rules.html#js_bottom" rel="nofollow">http://developer.yahoo.com/performance/rules.html#js_bottom</a> says
  "Put Scripts at the Bottom" for Speeding Up Your Web Site. Lets say I have added them at bottom </p>
  
  <pre><code>&lt;html&gt;
  &lt;head&gt;&lt;/head&gt;
  &lt;body&gt;
  ...
  ...
  ...
  html
  ....
  &lt;script src="script1"/&gt;
  &lt;script src="script2"/&gt;
  &lt;script src="script3"/&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Now if I have the requirement to access some function of those js files somewhere in the middle of html, how would I do that? Let's say the code is like this</p>
  
  <pre><code>    &lt;html&gt;
      &lt;head&gt;&lt;/head&gt;
      &lt;body&gt;
      ...
      ...
      ...
      html
      .....
  &lt;script&gt;
  $('a.test').modal('show);
  &lt;/script&gt;
      ....
      &lt;script src="script1"/&gt;
      &lt;script src="script2"/&gt;
      &lt;script src="script3"/&gt;
      &lt;/body&gt;
      &lt;/html&gt;
  </code></pre>
  
  <p>Above "$", "modal" etc are the part of js libraries attached at the bottom of the page. How will I detect the completion of bottom scripts and fire the code written in script tag (</p>
  
  <blockquote>
    <p>$('a.test').modal('show);</p>
  </blockquote>
  
  <p>) </p>