Learn HTML by Building a Cat Photo App - Step 15

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

                  The Curriculum Section:

         Step 15 for HTML by Building a Cat Photo App.

The step is requesting me to Turn the image into a link by Surrounding it with necessary element tags.

It appears to me that I have accomplished this task with the following code;

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

However, by code continues to fail and provides the following HINT;

“Your anchor (a ) element should have an opening tag. Opening tags have this syntax: <elementName> .”

I think the syntax is correct but I could be wrong.

                            MY QUESTION?

Is the placement of the (a) element incorrect in the above code I wrote? And/ or are there additional errors present?

Note: I attempted to try and figure this out on my own using google and previous posts made here as my source; but to no avail. That said, I hope I was clear in my explanation. Please forgive me if my format for this post did not meet customary standards. I am a novice in this arena. Critiques are welcomed.

IamShng.

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" href="https://freecatphotoapp.com">cat photos</a>.</p>
      <img <a target="_blank" herf="https://freecarphotoapp.com" src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back."></a>
    </main>
  </body>
</html>

You put a html tag inside of a html tag. That is not valid.

You must not change the img element at all. You need to put an opening anchor tag before the img element and a closing anchor tag after the img element.

1 Like

in addition to what Jeremy said, you need to watch the typos.
You have a few…

1 Like