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 trialStacey Fenton
5,501 PointsHow do you make the h1 tag green?
I have the following CSS code before the h1 tag (still in the body), but I keep getting errors: <style> h1 {color=green; } </style>
5 Answers
jeremywhiteford3
13,297 PointsI just posted an answer on this form...
Mike Stewart
4,984 PointsIt looks like you have a syntax error. As Csaba said, try using a semi colon (:) instead of an equals, so it should look like this... h1 { color: green; }
chrisp
13,686 PointsHere is a combination that would also work.
External CSS h1 { color: green; }
Internal CSS - between the open and closing head tag < style > h1 { color:green; } < /style >
Inline css within html tags < h1 style="color:green;" > Text < /h1 >
Core HTML < h1 >< font color="green" > Text < /font >< /h1 >
Csaba Todor
3,753 Pointsh1 { color: green; }
Stacey Fenton
5,501 PointsThese answers worked - thanks so much for the help!