Make an Image Responsive Your img tag should have a display set to block

Tell us what’s happening:
I am not able to get past the display: block. I have used both Chrome and Firefox, rewritten it, tried copying and pasting, closed my browser, reset the test…the other two parameters in this challenge are passing.
I read all the other help posts and played around with everything.
I appreciate the help and time. ~Shelly

Your code so far


<img {
max-width: 100%;
display: block;
height: auto;
src="" alt="freeCodeCamp stickers set">

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:62.0) Gecko/20100101 Firefox/62.0.

Link to the challenge:

Think about whether you need to use CSS or HTML to solve this challenge. Answer is in the first sentence of the challenge. hope that helps!

I think you are conflating, inline-style with internal stylesheet.

Thank you! I put the solution under style and it worked. I had tried that, I thought, but I must have had something incorrect.
Thanks for the quick reply and also the help, but not just giving me the solution. :slight_smile:

1 Like