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

Luke Svarc
Luke Svarc
1,338 Points

Set all sides to zero margin

Hi guys,

I am currently on the quiz where it asks to select the ID Gallery and remove margin, padding and bullet points.

I'm struggling to see where my code is wrong, can anyone offer any advice?

Thanks

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;
}

img {
  max-width: 100%
}

gallery {
  margin: 0;
  padding: 0;
  list-style: none; 
}
Luke Svarc
Luke Svarc
1,338 Points

In this code I realised the max-width: 100% is missing the ; I have added this now and still no luck

Luke Svarc
Luke Svarc
1,338 Points

In this code I realised the max-width: 100% is missing the ; I have added this now and still no luck

3 Answers

Haydn Ellen
seal-mask
.a{fill-rule:evenodd;}techdegree
Haydn Ellen
Python Development Techdegree Student 22,243 Points

You don't appear to have set gallery as a class, it should be .gallery (with a . in front of it). So the code would be:

.gallery { margin: 0; padding: 0; list-style: none; }

You just need to remember . goes before a class, # goes before an id and all is good :).

Luke Svarc
Luke Svarc
1,338 Points

Thanks Haydn,

Very infuriating but I will try to remember in the future!

Thanks for your help.