Hi,
I was trying to do the Technical Documentation Page, I was only making the structure of the page with some text, following the questions to make it working as it should do.
When I try executing the code it gives me two errors that I don’t know how to fix:
None of your header
elements should be empty.
Each .nav-link
should have text that corresponds to the header
text of its related section
(e.g. if you have a “Hello world” section/header, your #navbar
should have a .nav-link
which has the text “Hello world”).
In my code all header
elements are not empty and they are correctly linked to .nav-link
elements as requested.
These are the only errors displayed when I execute the code, all other requests are working.
Hope someone can help me fixing the code.
This is my code
<!-- file: index.html -->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="styles.css">
<title>Documentation Page</title>
</head>
<body>
<main id="main-doc">
<nav id="navbar">
<header>Docs</header>
<ul>
<li><a class="nav-link" href="#javascript">javascript</a></li>
<li><a class="nav-link" href="#java">java</a></li>
<li><a class="nav-link" href="#html_css">html css</a></li>
<li><a class="nav-link" href="#php">php</a></li>
<li><a class="nav-link" href="#android">android</a></li>
</ul>
</nav>
<section class="main-section" id="javascript">
<header>javascript</header>
<p>first p in <code>javascript</code></p>
<p>second p in javascript</p>
</section>
<section class="main-section" id="java">
<header>java</header>
<p>first p in <code>java</code></p>
<p>first p in java</p>
</section>
<section id="html_css" class="main-section">
<header>html css</header>
<p>first p in <code>html css</code></p>
<p>first p in html css</p>
<ul>
<li>first li</li>
<li>second li</li>
<li>third li</li>
<li>fourth li</li>
<li>fifth li</li>
</ul>
</section>
<section id="php" class="main-section">
<header>php</header>
<p>first p in <code>php</code></p>
<p>first p in php</p>
</section>
<section id="android" class="main-section">
<header>android</header>
<p>first p in <code>android</code></p>
<p>first p in android</p>
</section>
</main>
</body>
</html>
Challenge: Technical Documentation Page - Build a Technical Documentation Page
Link to the challenge: