Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

HTML How to Make a Website Customizing Colors and Fonts Use Color in CSS

Ryan Schmelter
Ryan Schmelter
9,710 Points

When I write in border color after background in css rule, it deactivates background. Same in reverse.

Example:

header { background: #6ab47b border-color: #whatever } Once I add border-color, the orange indicating background is active turns to black. Same thing happens to border-color if i switch them.

1 Answer

Steven Parker
Steven Parker
221,902 Points

You forgot to put a semicolon (";") between your properties.

Without the semicolon, the added code causes a syntax error and the whole line is ignored.

It's a good practice to always end a property and value pair with a semicolon, even if it's the only one in the rule.

Ryan Schmelter
Ryan Schmelter
9,710 Points

That was it. Thanks, Steven.