Tell us what’s happening:
- Your first section element should have an id attribute with the value upcoming-events.
- Your second section element should have an id attribute with the value past-events.
- Inside the #upcoming-events section, you should have an h2 element with the text Upcoming Events.
- Inside the #upcoming-events section, you should have two article elements below the h2 element.
It shows that I have failed 14-26.
I have copied my code into validator, and it says everything is correct. Help!
Your code so far
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Event Hub</title>
</head>
<body>
<header>
<h1>Event Hub</h1>
<nav class="class">
<ul>
<li><a href="#upcoming-events">Upcoming Events</a></li>
<li><a href="#past-events">Past Events</a></li>
</ul>
</nav>
</header>
<main>
<section id ="#upcoming-events">
<h2>Upcoming Events</h2>
<article>
<h3>Event 2025</h3>
<p>Event description</p>
<p>Date: 2025</p>
</article>
<article>
<h3>Event 2025</h3>
<p>Event description</p>
<p>Date: 2025</p>
</article>
</section>
<section id ="#past-events">
<h2>Past Events</h2>
<article>
<h3>Event 2024</h3>
<p>Event description.</p>
<p>Date: 2024</p>
<img src="https://cdn.freecodecamp.org/curriculum/labs/past-event1.jpg" alt="Oldfashionedcomputer">
</article>
<article>
<h3>Event 2024</h3>
<p>Event description.</p>
<p>Date: 2024</p>
<img src="https://cdn.freecodecamp.org/curriculum/labs/past-event2.jpg" alt="3Dboxes">
</article>
</section>
</main>
</body>
</html>
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36 Edg/138.0.0.0
Challenge Information:
Build an Event Hub - Build an Event Hub
https://www.freecodecamp.org/learn/full-stack-developer/lab-event-hub/lab-event-hub