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

HTML How to Make a Website Customizing Colors and Fonts Use Classes in CSS

Is the element nav a.selected { color: 32673f;} functions the same as the behavioral pseudo class named active?

Hi, I just encountered hover, active, and visited pseudo class types in a tutorial. Does the element "nav a.selected" that Nick has in the video, be considered as the equivalent if I use the pseudo class type "active"?

Aiden Berzins
Aiden Berzins
23,837 Points

They usually act very similar especially when it comes to links or a tags. However they are slightly different. The best example I can think of is the links at the top of the treehouse page when on is selected the link should immediately load having no time to show you the selected state however if you are on a certain page the page will show its active state as a slightly brighter font color.

Unlike for instance radio buttons that you will see when they are selected.

Antti Lylander
Antti Lylander
9,686 Points

Try moving on the page by hitting tab a few times and you see what 'active' means.

1 Answer

Thank you for the responses. It's clear to me now.