Stuck on adding images on HTML

I keep seeing this message when I run the test: “Your image should have a src attribute that points to the kitten image”

My code so far is:

CatPhotoApp

"this

Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.

Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.

I am following the instructions step by step a lot of times but I keep seeing that message. I don’t understand what I am doing wrong. Please help thanks!

Challenge: Add Images to Your Website

Link to the challenge:

Go ahead, and EDIT and preformat the code that you have already pasted, so people can help you with it.

Or, Cut and Paste the PREFORMATTED Code Again.


To share code, you can use the Preformatted text button.
This allows you to share the Source Code :

Just select the code that you want to keep raw, and press the button.

top

The image on the right is raw code .


1 Like

Can you show the code you used? That’s giving you the error msg ?

"thisPreformatted text

<img src="https://global.discourse-cdn.com/freecodecamp/original/3X/6/1/61a3499c5abb165be990aa0c1abd23342e60c663.jpg" alt= "this is a cat">

Thank you: This is my code do far:

CatPhotoApp

"this

Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.

Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.

<h2>CatPhotoApp</h2>

<main>

<img src="https://global.discourse-cdn.com/freecodecamp/original/3X/6/1/61a3499c5abb165be990aa0c1abd23342e60c663.jpg" alt= "this is a cat">

  <p>Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>

  <p>Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.</p>

</main>
1 Like

The problem is with the source of the img
Try using this link instead

https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg

And you should be fine
Have fun coding :v:

1 Like

Thank you so much for your quick reply sharptessa1. It worked!

So , how do I know when a source of an image is wrong? just asking in case I encounter the same issue in the future…

1 Like

Common mistakes is when you trying to add an image from your folder on your device sometimes a “wrong spelling” or wrong " / " could mess the whole thing up

But from the web

It’s pretty straight forward just copy the link where find the image and paste it in your code always remember to have it quoted " " and you should be good to go

Hope this helped and my answer wasn’t confusing

You are very helpful sharptessa1
Yes I did copy the link address from the website but it was still not working. But that’s fine, important is that I managed to move forward :slight_smile:

The reason why didn’t work was cus your assignment was specific it was written to use the code I sent you in the tutorial

Ok I see, thank you!