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 How to Make a Website Customizing Colors and Fonts Write Hexadecimal Colors

Anders Lund
Anders Lund
3,061 Points

Don't understand this question

"Set the color of paragraphs to black using a hexadecimal value"

simple enough to write the code to the specific element/thing and set the right color (#000?) but don't recall what a paragraph is in css...

5 Answers

Julian Gutierrez
Julian Gutierrez
19,201 Points

p is used to select a paragraph in css.

p{
    color:#000000; 
}

Infact paragraph is a specific element in itself. You have probably got 60% of your answer correct with the short hand form of hexadecimal value #000.

<p>Some text</p>

In HTML you could have easily written your content without the use of the <p*>* tag. So why use it?

When you write text in HTML without it being embedded inside a tag like h1, h2, the browser will interpret it as it is. The paragraph tag like Julian rightly mentioned is to select a paragraph and thus will properly indent the text within the p tag in a new line, like an actual paragraph

Hope it helps

Anders Lund
Anders Lund
3,061 Points

okey, but this is sort of like a assignment they have here and the task is "Set the color of paragraphs to black using a hexadecimal value"

this is the code, in CSS

a { text-decoration: none; }

wrapper {

max-width: 940px; margin: 0 auto; }

logo {

text-align: center; margin: 0; }

h1, h2 { color: #fff; }

there is no HTML just CSS since I have to change the color of the paragraphs, and i feel like i have tried everything, but its probably something simple I have forgotten.

really appreciate the help!

Michelle Cannito
Michelle Cannito
8,992 Points

You add the code to the CSS file. You type it in. The answer is given above. I don't understand your confusion, so, sorry if this doesn't help.

Anders Lund
Anders Lund
3,061 Points

haha I got it now, i'm new to this... okey :) it's complicated