Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

faq-accordoin-card-component

Saman 120

@samanthewebdev

Desktop design screenshot for the FAQ accordion card coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Overall this project was easy but its not working js in it isn't working and i check the code many times but idk why still not working!

Community feedback

CyrusKabir 1,885

@CyrusKabir

Posted

Hello my dear friend ♥ actually the big reason it is you put your script tag before all DOM elements; here is some links about this problem : where-should-i-put-script-tags-in-html, script tag palcement, and the problem it's not just your tag placement after your js have whole DOM elements you add this style .active img .... for that arrow icon but you didn't add .active .answer {display: block} for showing answers. hope this solve your problem. good luck♥

1

Saman 120

@samanthewebdev

Posted

@CyrusKabir hey i tried this but it still doesn't work for me.

0
CyrusKabir 1,885

@CyrusKabir

Posted

@saman2620 Update the github code so I can find the problem

1
Saman 120

@samanthewebdev

Posted

@CyrusKabir uhh where? i have this project repo on github and my github account is this what i have here u can add me there on github n then u can see it there o guess.

0
CyrusKabir 1,885

@CyrusKabir

Posted

@saman2620 No, look, I mean, you said you did what I said and it did not work, but I did not see any change in the github code e.g your script tag still is before all DOM elements ,....

0
Saman 120

@samanthewebdev

Posted

@CyrusKabir no i have this project file on my laptop i change it from there i added scrip in bottom of the body tag just before closing tag; i also added it in the head with defer and asyc attribute but it still didn't worked

0
CyrusKabir 1,885

@CyrusKabir

Posted

@saman2620 yes, I also said you should add .active .answer {display: block} style to your css.

1
Saman 120

@samanthewebdev

Posted

@CyrusKabir hey thank u soooo much i did and it works now thank uuuu!

1
CyrusKabir 1,885

@CyrusKabir

Posted

@saman2620 your welcome, I am glad it was helpful ♥ good luck my friend

1

Please log in to post a comment

Log in with GitHub
Discord logo

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord