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 trialMatt Lehn
3,672 PointsI followed the example exactly. Why am I getting "Bummer! Don't forget your style tag" message?
This is what I have:
<style>
h1 { color: blue; } </style>
<h1>Something Else</h1>
Where am I going wrong?
6 Answers
Ken Alger
Treehouse TeacherMatt;
It sounds like you are on Task 3 of the Write a CSS Selector and Property* Challenge.
At the end of Task 2 your code should look similar to:
<body>
<style>
h1 {}
</style>
<h1>Nick Pettit</h1>
</body>
Task 3 asks that you set the color of the h1 element to green, correct? So you need to add the color selector inside the h1 element and assign it a property of green.
Here is the final code for that challenge.
<body>
<style>
h1 {
color: green;
}
</style>
<h1>Nick Pettit</h1>
</body>
For future questions on the forum, please utilize the Markdown Cheatsheet examples for code insertion into posts. Also, please remember to mark posts as "Best Answer" when finished with your question(s).
Ethan Lowry
Courses Plus Student 7,323 PointsDo you have it in <style>
tags in the head of the page, like it says?
Matt Lehn
3,672 PointsYes.
Matt Lehn
3,672 PointsAwesome! Thanks for the tip
Matt Lehn
3,672 PointsAnyhoo,
Try this again:
<style>
h1 {
color: blue;
}
</style>
<h1>Something Else</h1>
Why doesn't this work?
Ethan Lowry
Courses Plus Student 7,323 PointsYou need to put that last line of triple backticks on the line immediately below your code, not at the end of an existing line.
Also remember to leave comments, not new answers (everybody does this, unfortunately this page isn't well designed in that regard)
EDIT: Nevermind, looks like you or someone else fixed it :)
Ethan Lowry
Courses Plus Student 7,323 PointsAnd are the style tags in the <head>
tags of the page? (Might or might not matter. What you have looks correct honestly so I'm looking for things the challenge might nitpick on.)
Matt Lehn
3,672 PointsAha! Was getting tripped up on placement of <body>
tags. Thx for the help, guys! :-)
Ethan Lowry
Courses Plus Student 7,323 PointsEthan Lowry
Courses Plus Student 7,323 Points( If you want to see how to copy your code into questions / comments properly, check the Markdown Cheatsheet link on this page below the answer box etc. when you're leaving an answer/comment, then we might be able to spot what's wrong in the complete code. )