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 trialSara Parker
2,238 PointsI need help with my code
The grey square under the pictures won't show. Instead I get it beside and just a little bit under, not like Nick's. I would been nice if someone could check it out.
1 Answer
Steven Parker
231,122 PointsDo you mean that the images only cover half of the background, where his covers it completely?
On line 20 of main.css you have restricted the image to 50% of the container size, where he uses 100%. But that's only part of the issue because his images are also wider. To fill the entire area you could use "width" instead of "max-width" to enlarge the images.
Also I noticed on line 126 you have "padding: 5;
" instead of "padding: 5%;
".
Sara Parker
2,238 PointsSara Parker
2,238 PointsThank you, Steven!
I did what you told me, but still, the images will not cover completely. Can you see why?
https://w.trhou.se/5tbmvn30wd
Steven Parker
231,122 PointsSteven Parker
231,122 PointsI was suggesting using "width" instead of "max-width" on the
img
rule, not the wrapper (the same line where the 100% went). Changing that on the wrapper prevents the dynamic resizing from working.