I'm using jQuery at wordpress (@the HOME page) and the ready function doesnt work for me. I have a index.php which is including (php) a header, footer and a sitebar. I tested this code:
<script type="text/javascript" src="path_to_jquery/jquery-1.3.2.min.js"></script>
<script type="text/javascript">
$(document).ready(function() {
alert ("test text");
});
</script>
The alert (with the text "test text") is just not popping up immediately! It's only popping up after my sitebar has been loaded. This means while I'm seeing the index page (sitebar is not loaded yet) I have to wait a few seconds until the sitebar has finished loading, and only then the jQuery code is executed: the alert is popping up. So the ready function just wont work. Can anybody tell me why and how I can solve this problem? Thanks.