I am trying to fade out multiple divs at once and fade in one div after that completes. Here's the code:
if($(this).attr("id")==="benefits-button"){
$("#solar-about, #home-page, #process-page, #financing-page, #vendors-page, #consump-info-page, #smart-page, #wind-page, #about-page").fadeOut(750, function() {
$("#benefits-page").fadeIn(750);
});
}
When there are multiple divs in the selector, the fadeOut and fadeIn happen at the same time.
Question: How do I get the fadeIn after the fadeOut?
Thank you
class
instead of too manyid
s? – undefined