I'm trying to make an hidden div slide down on the click of a button and also wait for about five seconds before sliding back up. I've tried the delay() but i don't know if i'm not implementing it right. Also and when the div isn't hidden it just displays the image.
I have this so far /
Anyone knows what i'm doing wrong?
Thanks in advance..
I'm trying to make an hidden div slide down on the click of a button and also wait for about five seconds before sliding back up. I've tried the delay() but i don't know if i'm not implementing it right. Also and when the div isn't hidden it just displays the image.
I have this so far http://jsfiddle/2sMFn/3/
Anyone knows what i'm doing wrong?
Thanks in advance..
- 1 It should be slideUp not SlideUp... – Jerryf Commented Aug 24, 2012 at 15:10
3 Answers
Reset to default 5You're on the right track, but you have to change this:
$this.delay(5000).SlideUp(6000);
to this
$this.delay(5000).slideUp(6000);
as it's slideUp whithout the capitol "S" ?
FIDDLE
Try this:
$this.delay(5000).slideUp(6000);
following is the DEMO: http://jsfiddle/2sMFn/19/
function name is 'slideUp()' instead of 'SlideUp'. So use this :
$this.delay(5000).slideUp(6000);