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

Mohammed Asif Anwar
Mohammed Asif Anwar
5,380 Points

Question task css

hi i dont know what i am doing wrong here,

Select the unordered list with the class contact-info and set the font size to 0.9em. Then, remove all margin, padding, and list styling.

.contact-info ul{ font-size: 0.9em; margin: 0 auto; padding: 0; list-style: none; }

it is keep saying Be sure to set the font size to 0.9em.

4 Answers

Hi Mohammed,

The selector you're using .contact-info ul is a descendant selector. You're trying to select a ul that is a descendant of an element with a class of "contact-info". Here it's the unordered list that has that class.

So you would want to use ul.contact-info or just .contact-info

Also, you haven't entirely zeroed out the margins. Should be margin: 0;

Mohammed Asif Anwar
Mohammed Asif Anwar
5,380 Points

Select the unordered list with the class contact-info and set the font size to 0.9em. Then, remove all margin, padding, and list styling

so what I did is

.Contact-info { List-style: none; Padding: 0; Margin: 0; Font-size: 0.9em; }

but it is keep telling me please setup the font-size to 0.9em;

This is probably because you have uppercase letters in there. Especially .Contact-info

capitalization doesn't matter in css but html class and id names are case sensitive.

For this reason I would recommend consistent use of all lower case letters.

Mohammed Asif Anwar
Mohammed Asif Anwar
5,380 Points

actually I tried without capitol letters but still the same thing work, this task is for css, I don't know what I am doing wrong.

Maybe you need to refresh the page and start over.

The only thing wrong in the original code that you posted was the selector.

This will pass .contact-info { font-size: 0.9em; margin: 0 auto; padding: 0; list-style: none; }

and this will pass ul.contact-info { font-size: 0.9em; margin: 0 auto; padding: 0; list-style: none; }

I even took the css you posted in the answer with uppercase letters and it passes as well once I change the class name to lowercase so that it matches the html.

.contact-info { List-style: none; Padding: 0; Margin: 0; Font-size: 0.9em; } Again though, I recommend that you use lowercase for all property names but I'm just showing that it passes.

A few people do have problems with not getting correct code to pass. My only suggestion would be to refresh the page or perhaps close and reopen your browser.