In this article, we will share with you the tutorial on hiding the content between divs by class name in js. We hope it can help you.
...
bbbbb
ccccc
ddddd
...
Requirement: Use js to loop through the contents of all p tags with class="aa" and not display them, only display this part:
bbbbb
ccccc
ddddd
It’s a very simple method, you can try it.
Related recommendations:
How to use CSS to hide divs in HTML