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

CSS CSS Foundations Text, Fonts, and Lists Font Properties

Fedor Andreev
Fedor Andreev
6,438 Points

Stuck on, "finally italicize the text in the paragraph"?

What am I doing wrong?

p { font-style: italic; }

2 Answers

Richmond Lauman
Richmond Lauman
28,793 Points

Hi Fedor. Remember that in the previous questions for that quiz they also asked you to create a rule for the font family stack used in the paragraph element. Try including the rule for the font-family rule and your font-style rule which is correct) within the same declaration for the p element. Like so:

p {
  font-family: Baskerville, Times New Roman, Times, Serif;
  font-style: italic;
}
ANTONIO ALTAMIRANO
ANTONIO ALTAMIRANO
9,428 Points

you could also define it all in one font. p {font: italic 5px Baskerville, "Times New Roman", Times, serif;} when i first entered it i did not include the font-weight of 5px. I forgot about that small rule. In any case I entered a font-weight and the answer was accepted. Guil explains it close to the end of the first video.