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 trialgreg Schackert
46 PointsWANT CSS IN H1 TO CHANGE FONT COLOR
HELP WITH CSS SELECTOR AND PROPERTY
<h1>Nick Pettit</h1>
H1SPACE{ GREEN; BLUE;}
3 Answers
Aurelian Spodarec
10,801 PointsRe-watch the video.
you select h1 by writing
h1{
values
}
Jacob Herrington
15,835 PointsAny already existing element such as a div, h1, p, span, etc. can be selected in CSS simply by typing the element name followed by opening and closing curly braces:
h1 {
color: white; /* this is the attribute to change font color */
}
For more you can refer to this documentation, be fair warned, CSS selectors can get very complicated (and cool) quickly!
greg Schackert
46 PointsTHANK S FOR THE HELP
Jacob Herrington
15,835 PointsNo problem! Make sure to really understand how CSS selectors work and what a CSS rule is - understanding these basics is the only way to progress with this stuff.
Jason Anders
Treehouse Moderator 145,860 PointsJason Anders
Treehouse Moderator 145,860 PointsHey greg Schackert
I absolutely agree with him. Based on your submitted answer, I strongly suggest you review the video before proceeding with the course. In fact, Computer coding and CSS can be very complex. Therefore, I actually recommend completing the Digital Literacy Track before moving on. This track will give you the basics needed to progress nicely through the other tracks/courses.
Keep Coding! :)