Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript JavaScript and the DOM (Retiring) Getting a Handle on the DOM Select All Elements of a Particular Type

did not turn purple

const myList = document.getElementsByTagName('li')

for (let i = 0; i < myList.length; i += 1) { myList[i].style.color = 'purple'; }

Mark Casavantes
Mark Casavantes
2,880 Points

Hello Jennifer,

I did not know about clicking on the camera.

Thank you,

Mark

1 Answer

Jennifer Nordell
seal-mask
STAFF
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

Karl Russell Sumando Menil Hi there! Unfortunately, we can't rule out something incorrect in your HTML. It could also be your browser cache. You might consider clearing your cache to see if that helps.

If you would like to share all of your code, you can do so by clicking the camera looking icon on the upper right-hand side of your workspace. That will create a "snapshot" that you can link to us and we can look at all your code at once without affecting your work.

Let us know! :sparkles: