Edit: This is a confirmed bug in jQuery 1.3.1. It is fixed in jQuery 1.3.2.
I have a YUI menu control exactly like this sample with sub menus along the top.
I tried using Yahoo's code to initialize the menu :
YAHOO.util.Event.onContentReady("mnuTopNav", function() {
var oMenuBar = new YAHOO.widget.MenuBar("mnuTopNav", {
autosubmenudisplay: true,
hidedelay: 750,
lazyload: true
});
oMenuBar.render();
});
I am seeing issues with pages that have images that take time to load.
I noticed that the headings would instantly appear (Communication/Shopping/Entertainment), but that the little arrows indicating there are sub-items wouldn't appear until all images are loaded.
I thought this very strange. I even tried switching out the code to JQuery to see if would initialize before the images are done loading (thats what $(function()
i thought was supposed to do).
$(function(){
var oMenuBar = new YAHOO.widget.MenuBar("mnuTopNav", {
autosubmenudisplay: true,
hidedelay: 750,
lazyload: true
});
oMenuBar.render();
});
To my amazement I still had the same issue. The menu would not initialize until the whole page was loaded.
It is definitely the images that are being waited for.
Note: this problem is only in internet explorer. Firefox seems to raise this onContentReady event BEFORE the images are loaded.
Can i work around this problem?
Edit: This is a confirmed bug in jQuery 1.3.1. It is fixed in jQuery 1.3.2.