Disregard this question: I’ve simply confused <script src="..."></script> tag and <script> [some functions] </scipt> tags.
I have this function
function OnLoad()
{
ShowHideConfirmAnswers();
return true;
}
triggered by onload event:
<body onload=OnLoad()>
It works fine until I add src=”jquery-1.4.2.js” to the script element. From this moment I get “OnLoad is not defined” error, and the same happens to every other javascript function.
This line makes me think you’re using a script element like this:
And then you’re adding the
srcattribute to the element:Which won’t work. Once you add the
srcattribute to a<script>element, all data contained within the script element will be completely ignored by the browser. You have to use separate script tags for external and inline javascript: