This forum is now read-only. Please use our new forums! Go to forums

0 points
Submitted by Daniel Liptrot
over 8 years

i have cheaked it so many times and it still wont work

I have tried every method I know and it still wont work so can someone tell me were about’s I went wrong on this

h3 { font-family: Verdana; color: red }

p { font-family: Courier; font-size: 16px {

span{ background-color:yellow; }

Answer 5594304bd3292fc88a0000b5

2 votes

Permalink

Missing semicolons on the end of color:red and font-size:16px Should look like color: red; font-size: 16px;

Also put a space here - background-color: yellow;

points
Submitted by Kevin Lin
over 8 years

Answer 5594e669d3292fbc79000574

0 votes

Permalink

the last css property (of a css selector) doesn’t need a semi-colon, this:

h3 {
font-family: Verdana;
color: red
}

p {
font-family: Courier;
font-size: 16px
{

span{
background-color:yellow;
}

and:

h3 {
font-family: Verdana;
color: red;
}

p {
font-family: Courier;
font-size: 16px;
{

span{
background-color:yellow;
}

are both perfectly valid, but as this guy describes here perfect, it is bad practice to leave out the semi-colon.

So, what is causing the error? your p css selector its closing curly bracket (}) is a opening curly bracket.

points
Submitted by stetim94
over 8 years