tags:

views:

146

answers:

1

I am trying to load a webpage using prototype.js in the header after the title.

I keep on getting an exception in the prototype.js within the CoreWrapper function, where the eventID is seen as a null.

This only happens once and then seems to be okay, thereafter. I have noticed that there is no problems loading the same webpage using Firefox.

Scanned on websites and looked for any possible updates for the javascript (1.6.0.3). Seems that the DOM Object is not loaded? Any ideas of how you can do this for internet explorer?

Please simplify this as I am very new to javascript :-)

A: 

Well, without code it's hard, but it might be because you don't wait until the DOM to be loaded or the complete page to be loaded before using some DOM functions. To wait for it just do something like this :

Event.observe(window, 'load', function(){

  //your code here

});
MaxiWheat