How to Put IDs on Elements collected with getElementsByClass

carla_rogers

New member
Two questions about how to work with the elements returned by getElementsByClass

QUESTION 1:
How can an id be added to all the elements that have been collected by the getElementsByClass . Basically, I want to cycle through the array returned from getElementsByClass('myclass'). IF an id already is on the element, would like to skip those.

QUESTION 2.
What data is included regarding all the elements collected by getElementsByClass.

I appreciate your help in learning this very important information. THANk you
 
Back
Top