Hello,
I am newbie to Javascript so I apologize if this is a stupid question (in keeping with the forum etiquette, I did a search as well but could not find anything that seemed relevant).
My problem is that I am trying to dynamically create some menus on a site but it only works part of the time in Firefox (but always if I debug using firebug) and never in IE.
I use the following to call the code on startup:
[CODE]window.onload = downloadXml(“menu.xml”, createMenus);
Where downloadXml is a function using a XMLHttpRequest to get access to my XML file and createMenus is a function that grabs a particular div tag in the HTML DOM and then appends children based on elements in the XML DOM.
Is it possible there is some sort of timing problem that prevents Firefox from grabbing HTML/XML elements before they have been put in the DOM?
For full code please see
[url]http://anataphoto.com/scripts/ajaxframework.js
[url]http://anataphoto.com/scripts/tabmenu.js