Select Chapter ❯
jQuery Tutorial
- jQuery Introduction
- jQuery Selector
- jQuery Traversing
- jQuery Events
- jQuery Get/Set
- jQuery Add/Remove
- jQuery CSS
jQuery Effects
jQuery Ajax
jQuery Animate
With the help of jQuery animate() method you can add animation in elements
Syntax
$(selector).animate({style parameters},speed,callback);
Code Explanation
- It requires style parameters if you want to add any style in animation you can the css styles in that.
- It takes speed parameter as optional it can have following values "slow", "fast", milliseconds.
- Third parameter is also an optional you can five the function to execute after the animation completes.
Example of Animate
$("button").click(function(){ $("a").animate({font-size:'25px',color:'red'}); });