Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML How to Make a Website Creating HTML Content Create Navigation with Lists

Bummer! The Portfolio list item should link to "index.html"

This is a stupid bug that needs to be fixed.

index.html
<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Nick Pettit</title>
  </head>
  <body>
    <header>
      <a href="index.html">
        <nav>
        <ul>
          <li><a herf="index.html">Portfolio</a></li>
          <li><a herf="about.html">About</a></li>
          <li><a herft="contact.html">Contact</a></li>
        </ul>
        </nav>
        <h1>Nick Pettit</h1>
        <h2>Designer</h2>
      </a>
    </header>
    <section></section>
    <footer>
      <p>&copy; 2013 Nick Pettit.</p>
    </footer>
  </body>
</html>

Oops guys that's not actually my code. That's someone's wrong code that I copied into it AHAHA

Steven Parker
Steven Parker
231,275 Points

Update it with your actual code and I'll revise my hints to address the real issue.

2 Answers

Steven Parker
Steven Parker
231,275 Points

You've actually got multiple bugs here, but here's a couple of hints to help you to fix them.

The instructions said, "Create a navigation element with an unordered list element after the link inside the header.", but it looks like you placed your element inside the link. To be after the link, it would need to come after the closing tag of the link ("</a>").

Then, in your new links, you have properties named "herf" and "herft", but the actual property name should be "href".

I'll bet you can handle it now without a code spoiler. Once you get all those fixed, you should pass the challenge.

Dan Weru
Dan Weru
47,649 Points

Hello Robert, you're doing great. Your just need to correct your code a little ... all links should have a href attribute. The snippet you have provided has syntax errors.

Your code should be as follows:

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Nick Pettit</title>
  </head>
  <body>
    <header>
      <a href="index.html">
        <h1>Nick Pettit</h1>
        <h2>Designer</h2>
      </a>
      <nav>
        <ul>
          <li><a href = 'index.html'>Portfolio</a></li>
          <li><a href = 'about.html'>About</a></li>
          <li><a href = 'contact.html'>Contact</a></li>
        </ul>
      </nav>
    </header>
    <section></section>
    <footer>
      <p>&copy; 2013 Nick Pettit.</p>
    </footer>
  </body>
</html>