How to getElementByClass instead of GetElementById with JavaScript?

前端 未结 7 799
孤街浪徒
孤街浪徒 2020-11-22 09:33

I\'m trying to toggle the visibility of certain DIV elements on a website depending on the class of each DIV. I\'m using a basic JavaScript snippet to toggle them. The probl

7条回答
  •  傲寒
    傲寒 (楼主)
    2020-11-22 10:02

    Use it to access class in Javascript.

    
    

提交回复
热议问题