Simple div sliding
- Started
- Last post
- 17 Responses
- designbot
Hope someone can help. Trying to do something similar to what is currently on Apples site ( and probably a million others) with this menu:
(http://www.apple.com/iphone/)
I think it's a combination of Javascript and hidden div tags...but I'm not certain.
Anyone have a link or care to paste some code? Thanks in advance!
- designbot0
*when you hover over the menu links...it automatically slides to reveal the content for that category.
- juhls0
I'm working on this right now, and it's cool, but horrible once you want to get really fancy and once you start using multiple menus.
- Probably because I don't know lots of scripting, hehjuhls
- exactly why.zenmasterfoo
- I'm very frustrated, obviously. I'll think it's the greatest thing ever once I get it to work with other menus.juhls
- pylon0
Google 'ajax accordion menu'.
- zenmasterfoo0
it's a hide and show. you can grab the entire UI for this from the jQuery site. it's a simple plug and play. depending on what style you want you can include or leave out certain variables:
- designbot0
really juhls?
I am going to use it for a some pretty simple stuff. Basically a menu with different key points of a product...and when you hover over you get a very short text description.
....thought it would be a slick way to keep the page and design clean while having a decent amount of text hidden.
- creez0
heres a accordeon script wich does not use a javascript library(lightweight and easy to set up):
http://www.switchonthecode.com/t…
- monNom0
If I recall, the apple site uses Mootools, which has a canned accordion plugin.
http://demos.mootools.net/Accord…
you might need to dig in to the code for switch 'click' events for 'rollover'
- Mirpour0
^ would making it open on rollover work like this maybe`?
http://nonverbla.de/showcase/
not sure how he has done it but its really cool- I'd say yes. (ish). this looks closer: http://demos111.moot…monNom
- thats pretty cool tooMirpour
- juhls0
What would you say is the best framework?
jQuery? Prototype? Mootools? Especially for this particular function (accordion). I'm guessing more people like jQuery, since there are (I think) more scripts available for it and it's best to use one framework and stick to it.
- jevad0
jQuery
- Stugoo0
jquery hands down.
- moural0
jQuery + UI Core.
$("#div_id").accordion( { autoHeight: false , event: 'mouseover' } );
Done.
- epikore0
Can I get a horizontal version?
- zenmasterfoo0
yes. and scriptaculous is not supported like jQuery is. limited documentation and more code to do the same work. stick with jQuery for effects like these.