Technical Documentation Page - Build a Technical Documentation Page

**Tell us what’s happening:**The .nav link texts and the href attribute seems to be wrong… I’ve checked though several times…It says that the section/header text and the .nav link text doesn’t match. Also, the href text seems wrong…What am I missing here?

Your code so far


The challenge seed code and/or your solution exceeded the maximum length we can port over from the challenge.

You will need to take an additional step here so the code you wrote presents in an easy to read format.

Please copy/paste all the editor code showing in the challenge from where you just linked.

    <div id="nav">
    <nav id="navbar">
        <header id="nav-head">JS Documentation</header>
        <li><a href="#Introduction" class="nav-link"></a>Introduction</li>
        <li><a href="What_you_should_already_know" class="nav-link"></a>What you should already know</li>
        <li><a href="JavaScript_and_Java" class="nav-link"></a>JavaScript and Java</li>
        <li><a href="Hello_World" class="nav-link"></a>Hello World</li>
        <li><a href="Variables" class="nav-link"></a>Variables</li>
        <li><a href="Declaring_Variables" class="nav-link"></a>Declaring Variables</li>
        <li><a href="Constants" class="nav-link"></a>Constants</li>
        <li><a href="Data_Types" class="nav-link"></a>Data Types</li>
        <li><a href="Reference" class="nav-link"></a>Reference</li>
    <main id="main-doc">
<section class="main-section" id="Introduction">
    JavaScript is a cross-platform, object-oriented scripting language.</p>

      Client-side JavaScript extends the core language by supplying objects to control a browser and its Document Object Model (DOM).
      Server-side JavaScript extends the core language by supplying objects relevant to running JavaScript on a server.

<section class="main-section" id="What_you_should_already_know">
<header>What you should already know</header>
<p>This guide assumes you have the following basic background:</p>
  <li>A general understanding of the Internet and the World Wide Web (WWW)</li>
  <li>Good working knowledge of HyperText Markup Language (HTML).</li>
  <li>Some programming experience. If you are new to programming, try one of the tutorials linked on the main page about JavaScript.</li>

<section class="main-section" id="JavaScript_and_Java">
  <header>JavaScript and Java</header>
  <p>JavaScript and Java are similar in some ways but fundamentally different in some others.</p>
  <p>JavaScript is a very free-form language compared to Java.</p>

<section class="main-section" id="Hello_World">
  <header>Hello World</header>
  <p>To get started with writing JavaScript, open the Scratchpad and write your first "Hello world" JavaScript code:</p>
  <div id="box-code"><pre><code>function greetMe(yourName) { alert("Hello " + yourName); }

<section class="main-section" id="Variables">
  <p>You use variables as symbolic names for values in your application.</p>

<section class="main-section" id="Declaring_Variables">
  <header>Declaring Variables</header>
  <p>You can declare a variable in three ways:</p>
  <p>With the keyword var. For example,</p>
  <div id="box-code"><pre><code>var x = 42.</code></pre></div>

  <p>By simply assigning it a value. For example,</p>
  <div id="box-code"><pre><code>x = 42.</code></pre></div>
  <p>With the keyword let. For example,</p>
  <div id="box-code"><pre><code>let y = 13.</code></pre></div>

<section class="main-section" id="Constants">
  <p>You can create a read-only, named constant with the const keyword.</p>
  <div id="box-code"><pre><code>const PI = 3.14;</code></pre></div>
  <p>You cannot declare a constant with the same name as a function or variable in the same scope. For example:</p>
  <div id="box-code"><pre><code>// THIS WILL CAUSE AN ERROR function f() {}; const f = 5; // THIS
WILL CAUSE AN ERROR ALSO function f() { const g = 5; var g;
//statements }</code></pre></div>
<p>However, object attributes are not protected, so the following statement is executed without problems.</p>
<div id="box-code"><pre><code>const MY_OBJECT = {"key": "value"}; MY_OBJECT.key =

<section class="main-section" id="Data_Types">
  <header>Data Types</header>
  <p>The latest ECMAScript standard defines seven data types:</p>
    <li>Six data types that are primitives:</li>
      <li>Boolean. true and false.</li>
      <li>null. A special keyword denoting a null value. Because JavaScript is case-sensitive, null is not the same as Null, NULL, or any other variant.</li>
      <li>undefined. A top-level property whose value is undefined.</li>
      <li>Number. 42 or 3.14159.</li>
      <li>String. "Howdy"</li>
      <li>Symbol (new in ECMAScript 2015). A data type whose instances are unique and immutable.</li>
      <li>and Object</li>

<section class="main-section" id="Reference">
  <ul><li>All the documentation in this page is taken from <a href="">MDN</a></li></ul>

**end of code**

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/ Safari/537.36

Challenge: Technical Documentation Page - Build a Technical Documentation Page

Link to the challenge:

when you make a link you have to put the text of the link within the anchor element
As an example, above you have the word Reference -after- the anchor element, not within it.
Make sure your closing anchor tags are on the right, not the left, of the link text.

<li><a href="#Introduction" class="nav-link">Introduction</a></li>

Thank you for the reply. I did what you said…The text issue is solved but the href text isn’t…I cross checked… Yet, what am I missing here? It says that there’s something wrong with the href attribute.

can I see the new code? Also please post the wording of the test that is failing if any.
The href for the navbar should utilize the # symbol in front of the id of the element you are linking to.

I’ve edited your code for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.

See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (').

I see you are still not using the hashtag # in your href values. So far you only did it for #Introduction.
You need to fix the rest of the lines.

1 Like

My dumb brain…past 2 hrs for this.
Thank you so much…

1 Like

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