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!
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 trial

Reza Nadjmabadi
632 PointsI keep getting an error stating "bummer! it doesn't look like you set the maximum width on images yet.
the question asks: Add CSS that will allow all images to fill their parent element.
I inputted:
image{ max-width: 100%; }
I know that there is no parent element in CSS, so what should I do then? I have been looking for sources to help me out to give me insight to the problem or to just solve it.
2 Answers

Chris Shaw
26,663 PointsHi Reza,
Without been able to see the challenge in question I would say the problem is because you have image
instead of img
which is the HTML tag for images.
img {
max-width: 100%;
}

Reza Nadjmabadi
632 Pointsthank you for clearing up the misunderstanding I had with img.

Reza Nadjmabadi
632 PointsThanks guys this really helped me. I owe you one. so I have to use img instead of image, is that because CSS recognizes this key word?

Chris Shaw
26,663 PointsIn HTML the keyword img
is the tag name for the element so this is what you always need to use to target it.
Arthur Crocquevieille
15,612 PointsArthur Crocquevieille
15,612 PointsHey ! the selector for an image is img so you should try to use :