I’m trying to use jQuery to animate and show a hidden element, however at the moment I can only make it so it will toggle the element and not just show it only.
$("#testTab").animate({"height": "toggle", "opacity": "toggle"}, "slow" );
Basically I want to achieve:
$("#testTab").toggle("slow");
$("#testTab").toggle(true);
but that would make a double toggle and both parameters can’t go into one toggle?
If you’re trying to just make it so that you click it once, and it animates the showing of it, just use.
If you’re trying to make so that it toggles (click once it shows, click again and it hides, animation in both directions). Just use the toggle parameter, that’s what it does: