title: document.createElement('script')... adding two scripts with one callback
body: <p>I need to add prototype and then add scriptaculous and get a callback when they are both done loading. I am currently loading prototype like so:</p>
  
  <pre><code>var script = document.createElement("script");
  script.src = "http://ajax.googleapis.com/ajax/libs/prototype/1.6.1.0/prototype.js";
  script.onload = script.onreadystatechange = callback;
  document.body.appendChild( script );
  </code></pre>
  
  <p>I could do this by chaining the callbacks, but that seems like poor practice ( I don't want a silly chain of 20 callback methods when I need to load more scripts). Ideas?</p>