Part of good web design is keeping your web page size small. Anyone who uses ASP.Net knows that its default HTML rendering is often very bloated and relies heavily on tables for layout. A great solution to this problem is to use the CSS Friendly Adapters toolkit.
I was working on a website whose design called for a left sidebar panel with a drop down menu, really I guess it is a drop out menu. CSS Friendly adapters consider this is a vertical menu. The menu has a top level stack of menu items. When you hover over the menu items sub menus appear to the right. I was using the CSS Friendly adapters and found that my menu worked perfectly for Firefox. But as anyone who does web design knows Internet Explorer (IE) is another story.
In IE, and this was version 7, when I hovered over a top level menu item the submenu would appear to the right as expected. However, there was a gap between the top level link text and the submenu. When you moved the pointer off of the top level menu text the side menu would disappear. To be clear, in IE the only way a submenu would appear is if you were directly over the top menu text.
What fixed the problem for me was setting the background color for the top level ul. In my original test the page had a white background as did the top level menu as it simply inherited the color set for the page. The submenu did have a different color. In trying to debug I started to set background colors to to verify the widths of my various menu items. I gave the 'ul.AspNet-Menu' class identifier a background color of gray. That immediately fixed the problem. I could now move the pointer off of the menu text and the submenu would continue to display. In experimenting I then set the background color to white, making it the same color as the page but now explicitly setting it. To my suprise that also worked. So it seems that setting a background color, any color fixed this problem.
I cant say I understand the cause of this problem. Anyone doing web design is constantly amazed by the wierdness of IE. But this problem is to me one of the more bizzare. If anyone has any insight as to why this worked I'd love to hear from them.