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 trialNagendra Prasad
183 PointsChange the color of the h1 tag to purple.
Change the color of the h1 tag to purple.
<!doctype html>
<html>
<head>
<link href="styles.css" rel="stylesheet">
</head>
<body>
<h1 class="h1clolor">Welcome to My Web Page!</h1>
</body>
</html>
.h1color
{
background-color:purple;
}
2 Answers
Alejandro Byrne
2,562 PointsHey! Your code seems to be right... try to add a space between the : and purple. And make it look like this: .h1color { background-color: purple; } If that doesn't work, replace purple with #800080. Hope that helps!
Don Macarthur
28,430 PointsLooks like a typo to me.
In your h1 element, where you declare the class, you have it named as "h1clolor", but your css is targeting "h1color".
Alejandro Byrne
2,562 PointsAlejandro Byrne
2,562 PointsAnd by the way, you don't need to make the h1 a class. Just take away the class and replace the css style with h1.