By Popular Demand

Download TopMenu.ascx.  The zip file contains an example on how I broke apart the DHTML menu from BrainJar.com into an ascx, css and js file to make the thing a little more reusable in my app.  I didn't include the .vb file for TopMenu.ascx because there is no server side code on this guy quite yet.  But it works fine for normal navigational purposes.  I have it setup so the menu drops down automatically when you hover over some text, the demo on BrainJar you have to click to expand the menu.  I think mine works a bit better for my site's purposes. 

Once again, all this code represents is how to take the demo from BrainJar and put it in an ascx file for reuse, he's the DHTML wiz that made the menu happen :)  I just don't want Mike thinking that I'm trying to take his hardwork and pawn it off as my own - I just copied and pasted. 

Edit: Just when I thought it was safe.  It appears they wrote some code to hard code the width of a certain item in IE because of some sort of bug.  We'll, it goofs up the menu when you do this in Opera (Opera identifies itself as IE6 too).  Do a search for this code: 

// Fix IE hover problem by setting an explicit width on first item of
// the menu.

In the if statement for checking if browser.isIE == true, add in && browser.UserAgent.indexof("Opera") > 0 or something to that effect (I'm no javascript expert, I just muddled through the code)

No Comments