Learn HTML by Building a Cat Photo App - Step 15

Tell us what’s happening:
Describe your issue in detail here.

Your code so far

<html>
  <body>
    <h1>CatPhotoApp</h1>
    <main>
      <h2>Cat Photos</h2>
      <!-- TODO: Add link to cat photos -->
      <p>Click here to view more <a target="_blank"<a href="https://freecatphotoapp.com">cat photos</a>.</p>
      <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back.">
    </main>
  </body>
</html>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36

Challenge: Learn HTML by Building a Cat Photo App - Step 15

Link to the challenge:

Sorry stuck on this one now.

Your image should be nested in the ‘a’ element (an opening and closing tag).

   <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg"alt="A cute orange cat lying on its back."><a href= "https://freecatphotoapp.com"/a>

Sorry, I just missed your comment but this is what I’ve got so far.

please restart this step (to undo all code changes).

After that, work only on adding code to the img line. Do not add code anywhere else.

Refer to step 12 if you need to remember how to make something into a link. (we add anchor opening tag to the left of it, and closing tag to the right of it)

 <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back."img></a>

This is the latest I’ve got so far. I do have a question the is the relation to question 12 the <a target="_blank"> value that step 12 uses?

You should go back maybe farther to step 11 as this is where anchor tags are explained first.

Maybe try those steps again 11 and 12 until you understand how to form an anchor

1 Like

Will do. So is it just the anchor that is the problem?

well the img is the code given to you at the start, so you should not be modifying it at all
you need to add the anchor tags around the img
(just like you did in step 12 for the words “cat photos”)

Review steps 10/11 to see what constitutes an anchor tag (it has an opening and closing etc)

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.