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

Having problems linking the portfolio list to index.html. Code works in workspaces but not the assignment section.

am i doing something wrong?

index.html
<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Prince Ampong</title>
  </head>
  <body>
    <header>
      <a href="index.html">
        <h1>Prince Ampong</h1>
        <h2>UX Designer</h2>
    </a>
      <nav>
        <ul>
        <li><a href="index.html"></a>Portfolio</li>
          <li><a href="About.html"></a>About</li>
          <li><a href="contact.html"></a>Contact</li>
        </ul>
      </nav>
      </header>Sample Websites designs will go here</p></section>
   <footer>
    <p>&copy; 2016 PC Ampong.</p>
    </footer> 
  </body>
</html>

2 Answers

Jennifer Nordell
seal-mask
STAFF
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

It's because you've put your links inside your list items. You need to do it backwards. The list items are supposed to be inside the links. Currently, there is a link all set up there, but it's got no text or visual representation because it is closed out before the text begins. Take a look:

<nav>
       <ul>
         <a href="index.html"><li>Portfolio</li></a>  /* the link or anchor tags are on the outside so that the list item is contained inside the link */
          <a href="about.html"><li>About</li></a>
          <a href="contact.html"><li>Contact</li></a>
       </ul>
</nav>

Hope this helps! :smiley:

Thank you very much Jennifer! :)