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 trialErik Heyl
4,249 PointsCorrect way to include fallback in Code Challenge?
h1 { font-family: 'Changa One', 'sans-serif'; }
Is this not the correct way to include your font and fallback? I do this, in the code challenge and yet it keeps saying to include the sans-serif fall back...confused? Wondering if it could be perhaps because I'm on a VERY old XP machine?
3 Answers
Jason Anello
Courses Plus Student 94,610 PointsHi Erik,
If you put quotes around sans-serif
then the browser looks for a font named "sans-serif"
You want to leave the quotes off because you want to use the keyword sans-serif
Any font name keywords should be unquoted.
Erik Heyl
4,249 PointsYup, thanks Jason, just ran it through a CSS validator...I feel so dense. Onward!
Jason Anello
Courses Plus Student 94,610 PointsYou're welcome.
Did the validator say there was an error? There wasn't anything wrong with your css. It just wasn't what the challenge wanted.
Erik Heyl
4,249 PointsIt told me the same thing: that sans-serif was a generic fount name keyword and should be unquoted.