Chain animation for different element
Hello. I'm trying to have an effect happen after an effect for some other elements has finished.
- $(document).ready(function() {
- $("#about_div").toggle(function() {
- $(".work_divs").slideUp(600);
- $(this).slideDown();
I've tried
- $(document).ready(function() {
- $("#about_div").toggle(function() {
- $(".work_divs").slideUp(600,function() {
- $("#about_div").slideDown(); } // can't use this - it refers to .works_div?
- );
and a couple of variations. I increased the duration to slow it down (so I could see what's happening) but the effects occur simultaneously.
Thanks for any guidance, Andy.
Added: Actually, the slideUp seems to happen after the slideDown.