hello, i’m creating a tribute page and i’ve done all the steps even watched a youtube video on how to do everything. However when i go to check the steps it says ive done 9/10 . It tells me that the " 1. The element should responsively resize, relative to the width of its parent element, without exceeding its original size." i’ve already set the size in the CSS section so what could i be doing wrong?
it would be super helpful if you could share your code (codepen) with us. that way we can take a look and better assist you
are you able to see my code?
If you click on the
9/10 Passed button it will show you the error message.
Below is the error message from your tribute page
AssertionError: Image is not centered:
Hope that helps
so would i fix that on the css side or on the html side?
CSS, you need to make sure your image is centered.
BTW, the link of the image is broken and there isn’t an element with an id of ‘img’ make sure to correct that as well.
it doesn’t matter what image I use I always get that picture block and I typed " position: center;" but it still gives me 9/10 (obv without the quotes)
also it already says my image is centered so i don’t know where you found that its not centered
@tyshamar873 when a test fails Click the red button to see which test(s) are failing and text to help you correct the issue.
Be sure and read more than just the first line of the failing message. The ability to read and comprehend error messages is a skill you’ll need to acquire as a developer. Ask questions on what you don’t understand.
The failing message says
The <img> element should responsively resize, relative to the width of its parent element, without exceeding its original size. Try using the "max-width" style property : expected 'none' to not equal 'none' AssertionError: Try using the "max-width" style property : expected 'none' to not equal 'none'
Hint: Review your CSS. What are you styling versus what
id and element are used in your code.
that didn’t help at all
what didn’t help at all? who are you responding to?
your advice to look at what I’m styling vs what id and element didn’t help
Oh…then you didn’t take a good look at your code. I realize you think what you’ve written is correct but there is an error. You need to look at it closely. And the hint I gave should help you.
I made one change and all tests pass correctly.
im very confused. So i deleted the “#” replaced it with a “-” then gave it another “#” and then it worked. WHAT JUST HAPPENED?!? lol
Deleted what “#”? Where?
What would a “-” do since it does not represent a class or an id.
And what is working? Running tests still shows 9/10 passing. Did you save your changes?
You are on the right track though.
I deleted the # in from the img and added a dash to see if it would visibly change and nothing changed then i re-added the # in front of the img again and noticed that it had moved to the center. i saved and uploaded
i figured it out now. I don’t need the # in front of the img in order for it to be centered
That’s correct. And do you know why you don’t need the # in front of
is it because i didn’t have the # in front on HTML?