adding to window.onload event?
<p>I'm wondering how to add another method call to the window.onload event once it has already
been assigned a method call.</p>

<p>Suppose somewhere in the script I have this assignment...</p>

<pre><code> window.onload = function(){ some_methods_1() };
</code></pre>

<p>and then later on in the script I have this assignment</p>

<pre><code> window.onload = function(){ some_methods_2() };
</code></pre>

<p>As it stands, only <code>some_methods_2</code> will be called. Is there any way to add to the previous <code>window.onload</code> callback without cancelling <code>some_methods_1</code> ? (and also without including both <code>some_methods_1()</code> and <code>some_methods_2()</code> in the same function block). </p>

<p>I guess this question is not really about <code>window.onload</code> but a question about javascript in general. I DON'T want to assign something to <code>window.onload</code> in such a way that that if another developer were to work on the script and add a piece of code that also uses <code>window.onload</code> (without looking at my previous code), he would disable my onload event. </p>

<p>I'm also wondering the same thing about </p>

<pre><code>  $(document).ready()
</code></pre>

<p>in jquery. 
How can I add to it without destroying what came before, or what might come after?</p>
