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

CSS CSS Foundations Advanced Selectors UI Element States Pseudo-Classes

css syntax issue i think

Hi i have been asked to set color to blue and font-weight to bold. I entered this and it says set font-weight to bold how is this wrong please input[type="radio"]:checked + label { color:blue; font-weight:bold; }

2 Answers

Your code works for me... Here's what I used. Maybe check your input html elements?

input[type="radio"]:checked + label { color:blue; font-weight:bold; }
<input id="rad1" type="radio" name="rad"><label for="rad1">Radio 1</label>
<input id="rad2" type="radio" name="rad"><label for="rad2">Radio 2</label>

edit: ugh markdown...

Would this help? https://teamtreehouse.com/forum/stuck-on-ui-element-states-pseudoclasses-quiz

Try clicking on 'UI Element States Pseudo-Classes' on your posted question to see all forum posts about this video ;)