The first time I load the page in FF it works fine, but if the page gets reloaded the menu doesn't appear. In the JS Console within the browser it gives the error:
document has no properties
and clicking on the error message hilights this part of the code:
I've tried everything and I have no idea what to do. And the even stranger thing is that the first time I used the script on a blank page with just the <head> and <body> tags it worked fine in both browsers. As soon as I added it to the page that I'm actually going to use it on, the script got messed up. I didn't change anything when I put it on the second page so I'm not sure what happened... Can anyone help? Thanks in advance!