This forum is now read-only. Please use our new forums at discuss.codecademy.com.

CSS: An Overview Forum

View Course » View Exercise

147 points
Abd5433eaff066fe7f4562cf61959354?s=140&d=retro
Submitted by
mlacey3
over 3 years ago

H3 headings red

I am not sure on how to make all of the H3 heading all red via the style sheet. It is not very specific on how to make a single attribute a different color, font etc. every time I type in

p{
font-family:Courier;
background-color:yellow
font-color:red;

it makes every word red except the heading. what am I doing wrong


3 votes

permalink

Had the same problem but managed to fix it hope this helps if you get stuck make sure you learn what I did with the code as its vital in the other stages :D

P {
font-family:courier;
font-size:24}

h3 {
color:red
}

span {
background-color:yellow}

201 points
7c0478ede0e4a00be2b0290a4d2f30f3?s=140&d=retro
Submitted by
KingWezzly
over 3 years ago

4 Comments

543fc82f631fe988640020d7_382532424 Tobias Páez almost 3 years ago

Hello King, please P, it's not capital, so use lower case p.
Please remove font-size:24, because it's not required by exercise

543fc82f631fe988640020d7_382532424 Tobias Páez almost 3 years ago

also add ; inside h3 or at the end of each command

5268673f80ff339d3e00155a_441266598 Wisdomdog over 2 years ago

Uppercase P also works though.

5542b941e39efe5c3a000547_470864101 pyCoder96406 over 2 years ago

wtf why did I had to put the p element someone please answer


0 votes

permalink

Yea i know, not much help on this learning academy. I tried the same thing.
This what i typed and got a minor result:
font-color:red;
font-family:courier;
font-size:24;
background-color:yellow

277 points
Ae5393d9564ec4dcedec71a0dfa51b8f?s=140&d=retro
Submitted by
MrFixItHandymanService
over 3 years ago

1 Comment

543fc82f631fe988640020d7_382532424 Tobias Páez almost 3 years ago

You forgot to tell to which element you're applying the CSS style


0 votes

permalink

Figured it out: After p{ the font code} brackets. Make an additional bracket for your heading code this would be something like: h3 {color:blue;}

277 points
Ae5393d9564ec4dcedec71a0dfa51b8f?s=140&d=retro
Submitted by
MrFixItHandymanService
over 3 years ago

2 Comments

Ae5393d9564ec4dcedec71a0dfa51b8f?s=140&d=retro MrFixItHandymanService over 3 years ago

you don't need font-color: red in the p{tags}. remove it

Ae5393d9564ec4dcedec71a0dfa51b8f?s=140&d=retro MrFixItHandymanService over 3 years ago

Your right KingWezzly congrats on a job well done, I'm down to the last two courses in CSS. learned so much within the past couple of days. Keep it up it gets a little tougher in lists: ul, ol, and div classes.