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

what am i doing wrong ? i'm being asked to link portfolio to index.html. im doing exactly that and im still getting an

during this challenge, i'm being asked to link portfolio to index.html. im doing exactly that and im still getting an error message stating that portfolio needs to be linked to index.html???

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 href="Index.html">Portfolio</a></li>
        <li><a href="about.html">About</a></li>
        <li><a href="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>

4 Answers

anil rahman
anil rahman
7,786 Points

Should look like this:

Remove the list out of the a tag Then swap the capital i to lowercsse for index.html

<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>
Kyle Johnson
Kyle Johnson
33,528 Points

This is correct!

You are probably getting the error because you have index.html linked in the <ul> tag. Once you fix that, you will still get an error because the link in the Portfolio <li> needs to be lowercase.

Mark Pryce
Mark Pryce
8,804 Points

Remove the top anchor the one before your ul tag I don't think it's serving any purpose.

Edit. Or wrap your h1 and h2 tags in that anchor not your unordered list.

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

Happy coding :)

jsdevtom
jsdevtom
16,963 Points

Capital "I" in <a href="Index.html">Portfolio</a>

i just tried it with a capital and im still getting an error message

Ayaz Hussein
Ayaz Hussein
13,348 Points

Sorry for being late, But I think it should be lower case "i" in

<a href="Index.html">Portfolio</a>

as far as i remember from doing the portfolio website.