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 Adding Pages to a Website Add and Style Icons

Tommy Gebru
Tommy Gebru
30,164 Points

Adding pages to a website

<code>With the anchor elements inside the contact-info list still selected, set the background size to 20 pixels square. Then set the left padding to 30 pixels, with all other padding at 0.Bummer! Did you set the background size for contact-info links to 20px?</code> Whats wrong with my code?

a {
  text-decoration: none;
}
ul.contact-info {font-size:0.9em;
                                    margin:0;
                                padding:0;
                                list-style:none;
}
.contact-info a {display:block;
                            min-height:20px;
                            background:no-repeat;
                            background-size:20px;
                            padding-left:30px;
                            padding:0;                                                      
}

3 Answers

Theodore Kruczek
Theodore Kruczek
8,800 Points

First one is width and the second value is height. Great explanation of it here.

Theodore Kruczek
Theodore Kruczek
8,800 Points

Two problems. Background size and your padding:

background-size:20px 20px;
padding:0px 0px 0px 30px;  

Your padding-left works, but right after that you are reseting all padding to 0.

Tommy Gebru
Tommy Gebru
30,164 Points

The padding is something that slipped my mind. However are you telling me that by setting the values of background-size to, two and separate(top bottom) and (left right) this will result in a square? A 20 pixel square?