Doing it with style
photograph © Denis Tevekov | Dreamstime.com
It has been a long time in the development stage but it is now here. The answer to the variable width dropdown sub menus which works in IE6 and IE7. This has been an ongoing development since December 2007, but now with a little more 'css/javascript/expressions' knowledge has finally been solved.
My previous example all had the problem that IE6 and IE7 did not get the width of the links in the sub menus to be 100% of the containing <ul>, but with just a one line MS expression this can be fixed.
The expression looks at the width of the containing <ul> using the parentNode.parentNode.offsetWidth and resizes the link to suit. If your visitor has javascript turned off then the menu will still work, but not in the same way as Firefox etc.
This menu has been tested and works in IE6, IE7, Firefox, Opera, Safari(PC) and Google Chrome.
Because of all the time and effort spent in producing this demonstration I would ask that you respect my copyright.
This demonstration can be used subject to the following terms and conditions.
Your donations keep CSS PLAY running.
If your donation is for the use of a demo then please email me with the demo url after making your donation.