1. Show hidden features
Hide Hidden Show Properties
The default parameter is time, in milliseconds
$ (' button '). On (' click ', function () {
var content = $ ('. Header ');
if (content.is (': Visible ')) {
Content.hide (1000);
}else{
Content.show (1000);
}
2. Fade in and fade out
Fadein fade in fadeout fade
The default parameter is also the time instance:
$ ('. List>a '). On (' click ', function () {
var Thisindex = $ (this). index ();
Console.log (Thisindex);
$ ('. Img>img '). EQ (ThisIndex-1). FadeOut (1000);
$ ('. Img>img '). EQ (thisindex). FadeIn (1000);
});
3. Slide effect
Slideup Slidedown drop down
The default parameter is also the time instance:
var h3 = $ (' h3 ');
H3.next (). Hide ();
H3.on (' click ', function () {
if ($ (this). Next (). Is (': Hidden ')) {
$ (this). Next (). Slidedown (500);
}else{
$ (this). Next (). Slideup (500);
}
jquery Common Properties