Step 14 is confusing me

Step 14

Turn the image into a link by surrounding it with necessary element tags. Use as the anchor’s href attribute value.

When I click on the image, it says: Normally this link would bring you to another website! It works! This is a link to: ( in a pop up.

What is wrong?

  **Your code so far**
    <h2>Cat Photos</h2>
    <!-- TODO: Add link to cat photos -->
    <p>Click here to view more <a target="_blank" href="">cat photos</a>.</p>
    <a href=""</a><img src="" alt="A cute orange cat lying on its back.">
  **Your browser information:**

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

Challenge: Step 14

Link to the challenge:

The anchor element here is malformed.

  1. The image element needs to be between the opening and closing anchor tags to turn the image into a link

  2. You need a closing > on your opening anchor tag, like you have on the line above.

1 Like

This part is wrong:

You should put the img inside the <a> like this: <a ...><img ...></a>


so I’m close to getting it but my link doesn’t link in the anchor element. What should I do here

href=" A cute orange cat lying on its back.

NVM i got it!


Thank you. The explanation helped me!

1 Like