I’m trying to fade out the background with $("#background::before").animate({opacity: 0}, 2000); when I click the button. But it doesn’t seem to be targeting #background::before properly.
If I change it to anything else like $("h1").animate({opacity: 0}, 2000); it works just fine.
JQuery’s .FadeOut() and .FadeIn() don’t seem to work either.
I’m not sure what you mean. I’m changing the background image through #background with #background::before. If I just change #background, then all the child divs get faded as well.