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 trialNour El-din El-helw
8,241 PointsA CSS Selector
First time to see a selector like this:
label.light {
}
Can someone please clarify it to me?
Nour El-din El-helw
8,241 PointsOh! So that's like a more specific class selector? Like instead of selecting all elements with the light class it only selects the label element that has the class light. Am I right?
1 Answer
Steven Parker
231,261 PointsYou're right, that's a "combined selector" that uses both the tag name "label" and the class name "light". It will only match elements that have both.
eslam said
Courses Plus Student 6,734 Pointseslam said
Courses Plus Student 6,734 Pointslabel.light will select the label tag that has a class of light