|
Put your script at the bottom of the page and get rid of the unnecessary ready/load wrapper that is slowing down the loading of the page.
That might not fix the problem but at least you'll have your JavaScript where it belongs and will be able to tell if there are additional things it needs other than the entire HTML in the page before the script can run - and if it doesn't work properly there because of not everything it needs being loaded yet then you will know that it has to wait for the load event to be triggered.
|