13. Putting it all together - Error!


#1

ERROR MSG: Oops, try again. Did you remember to add the intro ID to the h2 header?
Do not understand why this code is not working!


<!DOCTYPE html>
<html>
	<head>
		<link type="text/css" rel="stylesheet" href="stylesheet.css"/>
		<title>Result</title>
	</head>
	<body>
	<div id="intro">
		<h2>Introduction</h2>
	</div>
	<div class="standout">
		<h3>Classes and IDs in CSS</h3>
		<p>Classes and IDs are super easy in CSS. You're using them right now!</p>
	</div>	
		<h3>Regular HTML Selectors</h3>
		<p>If you don't bother with a class or ID, an HTML element just gets
		   the regular CSS styling for that element—or the default styling if you
		   don't specify any particular styling on the stylesheet.
		</p>
	</body>
</html>

-----------------------------------------------------------

#intro {
    color:#B83C3A;
    }
    
.standout {
    color:#F7AC5F;
    font-family:Verdana;
    
    }


#2

You put it on the div you need to put it on the h2 header:

<h2 id="intro">H2 Header</h2>

#3

You need to remove the div's you typed above the h2, p and h3 and type them inside the h2/h3/p tag it self like so:

<h2 id="intro">h2 Header</h2>

<h3 class="standout">h3 Header</h3>

<p class="standout">Paragraph</p>

#4

Thank you very much. Will try that :slight_smile:


#5

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