+ 2
What did I do wrong in the img tag?
Cant figure out what I did wrong in the img tag. Any takers? Help is much appreciated. https://code.sololearn.com/WL69y4wzB7Zf/?ref=app
20 Answers
+ 3
This should be what you're looking for - https://2.wlimg.com/product_images/bc-full/dir_119/3565777/mens-customized-round-neck-t-shirts-1937292.jpg
+ 3
I'm currently on mobile, so it may be a little different from desktop. Once I got to the image, I just pressed down on it until a pop up screen appeared, where there was an option for viewing the image. Once I pressed that, it brought me to the image in a separate tab so I just copied the URL and posted it here.
+ 2
First off, nice code. d:
You didn't do anything wrong with the image tag per se, it's just the source that doesn't seem to work. Because the value of the src attribute leads to the actual Amazon page and not the image itself, it's not being recognized as an image and is therefore not being displayed.
Try changing it to this instead - https://images-na.ssl-images-amazon.com/images/I/51InVIt3OIL._AC_UY700_.jpg
+ 2
Thank you, for both the code comment and the help!
+ 2
Head to the page that has the image you're wanting, right click the image and press view image in new tab. This should bring you to just that image alone, so copy the URL at the search bar and the link should work as the source.
+ 2
If that's the case, try looking to see if there's an option labeled view image or open in new tab (something along the lines of viewing the image).
+ 2
Huh, that's really weird, I've never had that happen before :/
Could you send a link to the website, just so I could see if it works for me?
+ 2
How'd you do that?
+ 1
Oh also, the align = center attribute doesn't seem to work with the img tag? Is there another way to center it? Sorry for all the questions, html is not my main language
+ 1
Oh, thanks!
+ 1
How did you get that link? I'm having trouble finding the direct link to some of the other images
+ 1
Oh that was what I was missing. Thanks man
+ 1
Wait, the image I want doesn't have that option
+ 1
I see that option when I right click it in Google, but that just takes me to the website. When I right click on it in the website the only options that come up are to save the picture
+ 1
Sure, give me a minute
+ 1
This should be it
http://www.eprilla.com/mens-customized-round-neck-t-shirts.htm
+ 1
Huh, I wonder why my computer is acting up like that
+ 1
It works for me on my phone too
+ 1
It must just be something with the computer
0
No need to apologize, this is what the Q&A section is for!
In HTML5, the align attribute of any object is no longer supported. I find that the best way to center something is to surround it in the <center> tag, which will move it to the middle of the screen.
For example, your image tag would look something like this:
<center>
<img src = "https://images-na.ssl-images-amazon.com/images/I/51InVIt3OIL._AC_UY700_.jpg">
</center>