You know the type of typical drop down menu we see on sites which uses DHTML, my question is, is it possible to achieve the same sort of effect without using any javascript, just pure css?
| SitePoint Sponsor |





You know the type of typical drop down menu we see on sites which uses DHTML, my question is, is it possible to achieve the same sort of effect without using any javascript, just pure css?



if you want the menu to appear when you hover over it with the mouse, then yes*, however, if you want the user to click the menu to make the dropdown bit appear, you need to use javascript
* doesnt work in IE
I did something similar for my Sitepoint CSS competition entry:Originally Posted by Daz
http://contest.prestontalk.com/index/End_Of_The_Road/
It only works in CSS2-aware browsers though. IE/Windows just gets a fully expanded menu, if you can live with that. I can make something work for IE/Windows if you're using all <a> tags; the reason I couldn't do so for the competition was because the tags used were <h3> tags and not links.





Vinnie, I basically want to replicate something like this http://www.dynamicdrive.com/dynamici...nu/horizon.htm only I want to use <ul> and <li> tags for marking up my menu items and as I said, avoid js completely.
dbalsdon, yep, I don't want to click, just menu items to appear on mouseover. If someone could point me to a working example I'm sure I could figure the rest.
Actually, I just tried one of my ideas out. It didn't validate, even as HTML 4.01 Transitional. I'm afraid that if you want an all-CSS flyout menu you will have to forego IE/Windows compatibility.
Bookmarks