0
Why this code is not working properly?
https://code.sololearn.com/WaBBQzDkwiLs/?ref=app (This code is collected. I just changed the value of id. And then it is not working.) Is the value of ID is invalid?
3 Réponses
+ 3
What's not working? What do you expect it to do? I'm gonna guess and say that you don't want the second div displayed until after the setTimeout has finished. If that is the case you need to set the display type for the second div to none as its initial setting. You can do this with a little CSS. Put the following in your CSS tab and run it.
#a2 {
display: none;
}
+ 2
It's ok to be a noob, we all were at some point! Just try to be a bit more thorough when asking your questions. Give examples and be as clear as you can about what you need help with. You will get much better answers much quicker if you ask really detailed questions with explanations of what you're expecting and what is happening. Give example inputs, outputs, errors etc. The more we have to look over, reformat, and diagnose what we think your issues may be the more likely we will just pass and go on to a better asked question. Good luck and enjoy coding.
+ 1
Thank you ChaoticDawg 😍
Actually I'm very noob in Javascript 😅. Trying to learn.