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 trialMarguerite Holden
6,075 PointsHow do I style text-align:right and color:red to the <h1></h1> tags in the body.
I'm supposed to add style to 'Once Upon a Time' with text-align:right; and color:red; It doesn't matter what I do I can't get it right. Can someone help me?
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Once Upon a Time</title>
<style>
h1 {text-align:left; color:green}
</style>
</head>
<body><h1>Once Upon a Time<?h1></body>
</html>
1 Answer
Michael Afanasiev
Courses Plus Student 15,596 PointsHi Marguerite,
First, make sure you put a semicolon at the end of every value in your styling. Second, make sure your closing tags in your HTML do not contain any characters other than a forward slash /
Hope this helps. :)
Marguerite Holden
6,075 PointsMarguerite Holden
6,075 PointsThanks Michael for your valuable input. it helped much.