How to make it sideup and side down
when i use this it sides down then up??
$("button").click(function () {
$("p").slideToggle("slow");
});
How to make it sideup and side down
when i use this it sides down then up??
$("button").click(function () {
$("p").slideToggle("slow");
});
Use something like this:
$("button").click(function () {
$("p").slideUp("slow", function() {
$("p").slideDown("slow");});
});
Alternatively, you could create a custom animation.
Here's my version - jQuery methods always return the jQuery object, which allows you to string an animation together like this:
$("button").click(function () {
$("p").slideUp("slow").slideDown("slow");
});