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 Styling Web Pages and Navigation Make a CSS Image Gallery

Jesse Andres
Jesse Andres
430 Points

Can anyone provide me with the end result code

Can anyone provide me with the end result code for "How to make a website" id like to compare mine and see why on earth it's not working.

css/main.css
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;
}

h1 {
  font-family: Changa One, sans-serif;
  font-size: 1.75em;
  font-weight: normal;
}

2 Answers

The below code passes for its respective task. I added a few comment lines to show which Task was asking for what. Tasks 3 and 4 are for the same selector, but obviously are broken up over two different tasks. Hope this helps to see where you might have been getting it wrong.

For future reference, and to help you personally learn where you might be getting something wrong, also add in the code that you entered and was told it was wrong. That way, someone can let you know if your missing on syntax, or whatever else. That helps with retention.

/* Task 1 Completion */
img {
  max-width: 100%;
}

/* Task 2 Completion */
#gallery {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Task 3 Sets the "Float" and "Width" */
/* Task 4  Sets the "Margin", "Color", and "Background" */
#gallery li {
  float: left;
  width: 45%;
  margin: 2.5%;
  color: white;
  background: black;
}
Christian Blume
Christian Blume
10,424 Points

Hey Jesse,

I'm not sure what won't work, but I've spotted one error. Fonts with more than one word in the title have to be wrapped in double quotes:

h1 {
  font-family: "Changa One", sans-serif;
  font-size: 1.75em;
  font-weight: normal;
}