Learn HTML by Building a Cat Photo App - Step 18

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

Why am i being asked to add h2 element in a section where h1 does not exist? i have some ideas as to why, but why confuse? if its about order of priority, how can there be 2 <h2>?

Your code so far

        <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>

<!-- User Editable Region -->


<!-- User Editable Region -->


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: Learn HTML by Building a Cat Photo App - Step 18

Link to the challenge:

Not sure I understand the question but each h2 belongs to its own section

but the section doesnt have an h1?

It doesn’t need one. Preferably there should only be one h1 heading on the page, which in this case, would be the one located in the main element. Each section does not need a h1 and a h1 does not have to come before each h2 inside separate sections.

The links I posted have more info.

1 Like

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