instead of sticking it in the body onload, have you tried calling it in the header of the page:
<HTML>
<HEAD>
<SCRIPT LANGUAGE="Javascript">
function some_function()
{
}
some_function();
</SCRIPT>
</HEAD>
<!-- The Rest Of The Page -->
Comatose
Taboo Programmer
2,910 posts since Dec 2004
Reputation Points: 361
Solved Threads: 215
function();
What language is that written in? It isn't HTML or XHTML because they use to call Javascript.
felgall
Junior Poster in Training
50 posts since Aug 2004
Reputation Points: 13
Solved Threads: 1
Most times code within onload needs to be there because it references elements of the page that need to be loaded beforehand in order to be able to reference them. Moving the onload code to anywhere else will probably result in "object expected" errors because the part of the page that the script references hasn't loaded yet.
felgall
Junior Poster in Training
50 posts since Aug 2004
Reputation Points: 13
Solved Threads: 1