Search code examples
htmlimageamazon-web-servicesamazon-s3src

Img tag with image from Amazon S3 not working


I saved an image to my bucket and the url works. https://s3.us-east-2.amazonaws.com/aaronstestbucketpnw/Abraham-lincoln-quote-internet-hoax-fake.jpeg. I am having an issue adding it to an img tag.

<img src="url(https://s3.us-east-2.amazonaws.com/aaronstestbucketpnw/Abraham-lincoln-quote-internet-hoax-fake.jpeg)" alt="not working">

Here is jsfiddle.

https://jsfiddle.net/aaronmk2/98L9retf/


Solution

  • Use:

    <img src="https://s3.us-east-2.amazonaws.com/aaronstestbucketpnw/Abraham-lincoln-quote-internet-hoax-fake.jpeg" alt="not working">