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 trialJonas Eldi
8,152 PointsHelp me!!!!
I just can't figure out the answer to a question! I'm supposed to "Set the color of paragraphs to black using a hexadecimal code" but when i try it just won't work. I have tried many ways, and even on my own workspace the paragraphs become black when I use the same code, but in in the code challenge, they don't.. What am I doing wrong, or is there possibly an error with the challenge?
a {
text-decoration: none;
}
#wrapper {
max-width: 940px;
margin: 0 auto;
}
#logo {
text-align: center;
margin: 0;
}
h1, h2 {
color: #fff;
}
body p {
color: #111;
}
6 Answers
Zach Patrick
19,209 PointsThe hexadecimal value for black is #000; #111 would technically be a very dark grey.
The following answer is correct...
h1, h2 {
color: #fff;
}
p {
color: #000;
}
M. Cotter
6,179 PointsHi Jonas,
The code should read:
p {
color: #000;
}
because the hex value for black is #000000, or you could also write:
p {
color: black;
}
I hope this answers your question! If it did, please consider marking this as the Best Answer! :) If not, let me know what happens when you try this change, and I'll see what I can do to help.
M.
Richard Hope
25,237 PointsYou could try a six digit code??
Or it may be that #111 is not the shade of black they're after. Try using a lower number than 1??
Bryan Laraway
13,366 PointsThis worked for me:
a {
text-decoration: none;
}
#wrapper {
max-width: 940px;
margin: 0 auto;
}
#logo {
text-align: center;
margin: 0;
}
h1, h2 {
color: #fff;
}
p {
color: #000000;
}
Jonas Eldi
8,152 PointsWow.. guys you are lifesavers.. This challenge has bothered me for so long now.. Thanks a lot!! I must say I'm a little bit embarrassed right now!
Zach Patrick
19,209 PointsNo problem! It just takes a little getting used to.
M. Cotter
6,179 PointsNo worries! It's one of those things that can be hard to figure out when you're in it, but is more clear to an outside eye. What ended up working for you?
M.
Jonas Eldi
8,152 PointsThe
p { color: #000; }
worked for me! Thanks again!
M. Cotter
6,179 PointsNice! Very weird that it wouldn't accept #000000, but glad it's now working for you!
Happy coding!
M.
gabyfr
2,231 PointsHere's a page that has lots of hex colors in case you ever have the same problem. http://www.w3.org/TR/css3-color/#svg-color