Learn HTML by Building a Cat Photo App - Step 64-I've been stuck on this for too long

I’ve been stuck on step 64 for ages, I’ve tried taking away the p element, and asked for help on reddit and have watched videos on YT, inputting the code in different ways.

The code never works, and It keeps telling me that the ‘a’ anchor element is missing a closing bracket when it already has that.

<html>
  <body>
    <main>
      <h1>CatPhotoApp</h1>
      <section>
        <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>
        <a href="https://freecatphotoapp.com"><img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back."></a>
      </section>
      <section>
        <h2>Cat Lists</h2>
        <h3>Things cats love:</h3>
        <ul>
          <li>cat nip</li>
          <li>laser pointers</li>
          <li>lasagna</li>
        </ul>
        <figure>
          <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/lasagna.jpg" alt="A slice of lasagna on a plate.">
          <figcaption>Cats <em>love</em> lasagna.</figcaption>  
        </figure>
        <h3>Top 3 things cats hate:</h3>
        <ol>
          <li>flea treatment</li>
          <li>thunder</li>
          <li>other cats</li>
        </ol>
        <figure>
          <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg" alt="Five cats looking around a field.">
          <figcaption>Cats <strong>hate</strong> other cats.</figcaption>  
        </figure>
      </section>
      <section>
        <h2>Cat Form</h2>
        <form action="https://freecatphotoapp.com/submit-cat-photo">
          <fieldset>
            <legend>Is your cat an indoor or outdoor cat?</legend>
            <label><input id="indoor" type="radio" name="indoor-outdoor" value="indoor" checked> Indoor</label>
            <label><input id="outdoor" type="radio" name="indoor-outdoor" value="outdoor"> Outdoor</label>
          </fieldset>
          <fieldset>
            <legend>What's your cat's personality?</legend>
            <input id="loving" type="checkbox" name="personality" value="loving" checked> <label for="loving">Loving</label>
            <input id="lazy" type="checkbox" name="personality" value="lazy"> <label for="lazy">Lazy</label>
            <input id="energetic" type="checkbox" name="personality" value="energetic"> <label for="energetic">Energetic</label>
          </fieldset>
          <input type="text" name="catphotourl" placeholder="cat photo URL" required>
          <button type="submit">Submit</button>
        </form>
      </section>
    </main>
    <footer>
      <p><a href= "No Copyright - freeCodeCamp.org"</a> </p>

The challenge: 
Turn the existing `freeCodeCamp.org` text into a link by enclosing it in an anchor (`a` ) element. The `href` attribute should be set to `https://www.freecodecamp.org` .

The code I think is correct:

 <p>No Copyright - <a href="https://www.freecodecamp.org">freeCodeCamp.org</a></p>

</footer>
  </body>
</html>

Your browser information:

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

You have two copies of the p element. Don’t make any extra p elements!

Hi, I know you must have been frustrated but you didnt end the a with anchor element with a > tag

<p>No Copyright - <a> href="https://www.freecodecamp.org">freeCodeCamp.org</a></p>
Is this what you mean?
If so, I inputted this and it still won’t work.

Where is the opening a tag in this and the closing a tag?

No Copyright - <a href="https://www.freecodecamp.org">freeCodeCamp.org</a>

I inputted the code without the p elements and it still won’t work, this is what you meant right?

oh I forgot I’m on the html format, I edited the code.

No, don’t delete the p elements. Delete nothing from the starting code!

You need to not add a second p element. The code you posted had 2 p elements (and a bunch of extra text I assume wasn’t actually there!).

What is your full, current code?

<p>No Copyright - <a href="https://www.freecodecamp.org">freeCodeCamp.org</a></p>

Don’t I need to use a closing tag for the p element?
That’s why there are two p elements there: <p> and </p>

<html>
  <body>
    <main>
      <h1>CatPhotoApp</h1>
      <section>
        <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>
        <a href="https://freecatphotoapp.com"><img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back."></a>
      </section>
      <section>
        <h2>Cat Lists</h2>
        <h3>Things cats love:</h3>
        <ul>
          <li>cat nip</li>
          <li>laser pointers</li>
          <li>lasagna</li>
        </ul>
        <figure>
          <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/lasagna.jpg" alt="A slice of lasagna on a plate.">
          <figcaption>Cats <em>love</em> lasagna.</figcaption>  
        </figure>
        <h3>Top 3 things cats hate:</h3>
        <ol>
          <li>flea treatment</li>
          <li>thunder</li>
          <li>other cats</li>
        </ol>
        <figure>
          <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/cats.jpg" alt="Five cats looking around a field.">
          <figcaption>Cats <strong>hate</strong> other cats.</figcaption>  
        </figure>
      </section>
      <section>
        <h2>Cat Form</h2>
        <form action="https://freecatphotoapp.com/submit-cat-photo">
          <fieldset>
            <legend>Is your cat an indoor or outdoor cat?</legend>
            <label><input id="indoor" type="radio" name="indoor-outdoor" value="indoor" checked> Indoor</label>
            <label><input id="outdoor" type="radio" name="indoor-outdoor" value="outdoor"> Outdoor</label>
          </fieldset>
          <fieldset>
            <legend>What's your cat's personality?</legend>
            <input id="loving" type="checkbox" name="personality" value="loving" checked> <label for="loving">Loving</label>
            <input id="lazy" type="checkbox" name="personality" value="lazy"> <label for="lazy">Lazy</label>
            <input id="energetic" type="checkbox" name="personality" value="energetic"> <label for="energetic">Energetic</label>
          </fieldset>
          <input type="text" name="catphotourl" placeholder="cat photo URL" required>
          <button type="submit">Submit</button>
        </form>
      </section>
    </main>
    <footer>
      <p><a href= "No Copyright - freeCodeCamp.org"</a> </p>
           **<p>No Copyright - <a href="https://www.freecodecamp.org">freeCodeCamp.org</a></p>**

    </footer>
  </body>
</html>

The instructions do not ask you to make an extra p element. Do not do that!

I would reset the code and only add the a tags.

1 Like

Delete this, it is not needed

2 Likes

thank you very much, it passed :slight_smile:

4 Likes

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