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 trialIlhom Maksadkulov
3,121 PointsNot the same result as shown in Advanced Backgrounds topic
Here is the code:
height: 100%;
margin: auto;
background-image: url('../img/beachSquare.jpg');
background-size: contain;
But the background is positioned as in video. That is, not centered. But it is aligning left fillng another background repeat the same background image. What is wrong there?
1 Answer
Ilhom Maksadkulov
3,121 PointsI solved the problem myself. I forgot to write "background" instead "background-image". Also I forgot to include "no-repeat" and "center".