background preloader

Javascript

Facebook Twitter

Instant Documentation Search. How to Make a Smooth Animated Menu with jQuery. Ever seen some excellent jQuery navigation that left you wanting to make one of your own? Today we’ll aim to do just that by building a menu and animate it with some smooth effects. The Goal – One Smooth Menu Here’s a demo of what we’ll end up with by the end. Introduction – An explanation of easing The menu has such a smooth animation because of a thing called “easing”. Adobe’s definition in the Flash Developer Center is a little more complete: “The term easing refers to gradual acceleration or deceleration during an animation, which helps your animations appear more realistic. Thanks to the magic of the jQuery Easing plugin, we can now use easing outside of Flash and Actionscript environments. Step 1 – Set up the Structure Before starting with any jQuery, we’ve got to build a quick menu structure with XHTML and load in the required project files.

Nothing out of the ordinary here. Then copy in this menu structure into the body: Step 3 – Style with CSS Step 4 – Animate with jQuery Google+ Sexy Drop Down Menu w/ jQuery & CSS. Jun 02 2009 Studies show that top navigations tend to get the most visual attention when a user first visits a site. Having organized and intuitive navigation is key — and while most drop down menus may look aesthetically pleasing, developing them to degrade gracefully is also essential.

In this tutorial I would like to go over how to create a sexy drop down menu that can also degrade gracefully. View Demo of Sexy Drop Down Menu Step1. First create an unordered list for your base top navigation. <ul class="topnav"><li><a href="#">Home</a></li><li><a href="#">Tutorials</a><ul class="subnav"><li><a href="#">Sub Nav Link</a></li><li><a href="#">Sub Nav Link</a></li></ul></li><li><a href="#">Resources</a><ul class="subnav"><li><a href="#">Sub Nav Link</a></li><li><a href="#">Sub Nav Link</a></li></ul></li><li><a href="#">About Us</a></li><li><a href="#">Advertise</a></li><li><a href="#">Submit</a></li><li><a href="#">Contact Us</a></li></ul> Step2.

Step3. jQuery Conclusion Homepage. jQuery: The Write Less, Do More, JavaScript Library. Javascript Sliding Panels using Generic Animation. In this tutorial, we're going to combine the original tutorial on Sliding Panels with our new tutorial on Generic Animation. Using our generic animation code, making sliding panels becomes much easier.

You can download the Javascript code for generic animation here. For this tutorial, I'm going to show how to make a few different types of sliding panels. Hopefully you'll have a good understanding of how to use the generic animation code to make all sorts of interesting and unique sliding panels by the end of this post. Let's start with a standard vertical slider. In this example, when you click the header, the panel will contract and expand exactly like it does in our first sliding panel tutorial. Here's the HTML code required to make the above example. There's nothing too special about this code. As you can see, the Javascript code required to make a sliding panel has been reduced significantly from our original tutorial. Here's the HTML code: Source Files: