Learn HTML by Building a Cat Photo App - Step 15

Tell us what’s happening:

I am having trouble to solve this problem
I am not sure if i need to use the code target=“_blank”
and I am also not sure why the first anchor is now turning red like it did on the paragraph above

Your code so far

<html>
  <body>
    <main>
      <h1>CatPhotoApp</h1>
      <h2>Cat Photos</h2>
      <!-- TODO: Add link to cat photos -->
      <p>See more <a target="_blank" href="https://freecatphotoapp.com">cat photos</a> in our gallery.</p>

<!-- User Editable Region -->

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

<!-- User Editable Region -->

    </main>
  </body>
</html>

Your browser information:

User Agent is: OPR/102.0.0.0

Challenge Information:

Learn HTML by Building a Cat Photo App - Step 15

1 Like

No you do not need to add the target attribute. Just the href attribute is enough.

You are putting the anchor element inside of the img element. Instead the instructions are asking you to “Turn the image into a link by surrounding it with necessary element tags.” So the a tags should be surrounding the img tag, not nested inside of it. Similar to how you surrounded the words “cat photos” with a tags in the p element.

2 Likes

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