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

Scott Yardley
Scott Yardley
20,663 Points

In code challenge 1/3 on Customizing Colors and Fonts it wants me to include a font, but whenever I do it says I didn't.

Do you guys have any idea why not

5 Answers

Jonathan Handel
Jonathan Handel
4,877 Points

What is the code surrounding this?

Scott Yardley
Scott Yardley
20,663 Points

a { text-decoration: none; }

wrapper {

max-width: 940px; margin: 0 auto; }

logo {

text-align: center; margin: 0; }

h1, h2 { color: #fff; }

nav a { color: #fff; }

nav a:hover { color: #32673f; }

Jonathan Handel
Jonathan Handel
4,877 Points

You need to add a font family element to the CSS. Between the a element and the wrapper element, put in the following code:

body { font-family: 'Open Sans', sans-serif; }

See if that works.

Scott Yardley
Scott Yardley
20,663 Points

this is the code that i'v been trying

h1 { font-family: 'Changa one', sans-serif; margin: 15 px 0; font-size: 1.75em; } but that doesn't work any idea why?

Jonathan Handel
Jonathan Handel
4,877 Points

My first inclination is that you are putting the font-family in the h1 element and I think it's supposed to go in the body element. However, I'm not entirely sure so I'm going to review the lesson though and see what I can come up with.

Jonathan Handel
Jonathan Handel
4,877 Points

Is this the code challenge where the first one is to add a font then in the CSS add an font-family to H1 then the third one is to add size and weight?

Scott Yardley
Scott Yardley
20,663 Points

thanks for helping me out here.

Jonathan Handel
Jonathan Handel
4,877 Points

Not a problem, happy to help. If the challenge is the same as I think it is, then the issue might be the margin. When I re-did the code challenge, it asked for font weight and font size. Try adding font-weight: normal; to your code.

Scott Yardley
Scott Yardley
20,663 Points

thanx for all your help I think I got it now