23. Pseudo Selectors


#1

This is the error I get:
Oops, try again. Did you give your third paragraph a font-size of 26px? It looks like it's currently undefined.


<!DOCTYPE html>
<html>
	<head>
		<link type="text/css" rel="stylesheet" href="stylesheet.css"/>
		<title>Result</title>
	</head>
	<body>
		<h3 class="fancy">
		    <p class="fancy">Monkeys</p>
		    <p id="serious">Chimps</p>
		    <p>Gorillas</p>
		</h3>
	</body>
</html>


.fancy {
    font-family: cursive;
    color: violet;
}

#serious {
    font-family: Courier;
    color: #8c8c8c
}

body :nth-child(4) {
    font-size: 26px;
}

The funny thing is that if I change body :nth-child(4) to (3), the text changes and it shows that it works. It still gives me the error though.


#2

We would not normally write paragraph elements in a heading container. The heading should have its own line.

<h3>...</h3>
<p>...</p>

#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.