Welcome to the Treehouse Community
Looking to learn something new?
CSS: background-image has to be before background-color?
I was watching CSS Foundations > The Box Model > Backgrounds. I was following the lesson using Sublime Text 2 and Google Chrome to view the page changes.
As per the demo, I tried to set background-image: url('../images/fox.png'); after background-color: #777 and Sublime was showing me that background-image line was not completed properly (the text was plain white instead of styled). I ignored it, saved and refreshed the page. Nothing displayed. I moved the background-image line ABOVE the background-color line and everything worked perfectly.
Any idea why this is happening?
Aaron Martone3,290 Points
After showing your code, I would try to get familiar with Firebug on Google Chrome. It is an unfathomably wonderful tool that will help you troubleshoot these kinds of issues.
The sequence of order between these two properties should be no difference. Were you using background-image or just background? The latter is shorthand and can sometimes override things if we don't make the discernment.