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 Adding Pages to a Website Add a New Page

When I preview and hit about its not taking me to About.html..

<!DOCTYPE html>
<html>
  <head>
    <link rel="stylesheet" href="css/normalize.css">
    <link href='https://fonts.googleapis.com/css?family=Changa+One|Open+Sans:400,400italic,700,700italic,800' rel='stylesheet' type='text/css'>
    <link rel="stylesheet" href="css/main.css">
    <style>
      footer {
        color: #1111af
      }

    </style>

    <meta charset="utf-8">
    <title>Kito Middleton | designer</title>
  </head>
  <body>

    <header>
     <a href="index.html" id="logo">
       <h1>Kito Middleton</h1>
       <h2>Designer</h2>
     </a> 
     <nav>
       <ul>
         <li><a href="index.html">Portfolio</a></li>
         <li><a href="index.html">About</a></li>
         <li><a href="index.html">Contact</a></li>
       </ul>
     </nav> 
    </header>

    <div id="wrapper">
      <section>

        <img src="img/nick.jpg" alt="photograph of nick" class="profile-photo">
        <h3>About</h3>
        <p>Hi...</p>
        <p>If you would like to follow me on twitter my user name is <a href="http://twitter.com/kitomiddleton">@Kitolm</a>.</p>

        </section>
        <footer>
          <a href="http://twitter.com/kitomiddleton"><img src="img/twitter-wrap.png" alt="twitter" class="social-icon"></a>
          <a href="http://twitter.com/kitomiddleton"><img src="img/facebook-wrap.png" alt="facebook" class="social-icon"></a>
          <p>Ā© 2016 Kito Middleton.</p>
        </footer>
      </div>

</body>
</html>
<!DOCTYPE html>
<html>
  <head>
    <link rel="stylesheet" href="css/normalize.css">
    <link href='https://fonts.googleapis.com/css?family=Changa+One|Open+Sans:400,400italic,700,700italic,800' rel='stylesheet' type='text/css'>
    <link rel="stylesheet" href="css/main.css">
    <style>
      footer {
        color: #1111af
      }

    </style>

    <meta charset="utf-8">
    <title>Kito Middleton | designer</title>
  </head>
  <body>
    <header>
      <a href="index.html" id="logo">
         <h1>Kito Middleton</h1>
         <h2>Designer</h2>
       </a> 
       <nav>
        <ul>
          <li><a href="index.html" class="selected">portfolio</a></li>
         <li><a href="index.html">About</a></li>
         <li><a href="index.html">Contact</a></li>
       </ul>
     </nav> 
    </header>

    <div id="wrapper">
      <section>
          <ul id="gallery">
            <li>
              <a href="img/img1.jpg">
                <img src="img/img1.jpg" alt="">
                <p>Expiermentation with texture and color.</p>
              </a>  
            </li>
            <li>
              <a href="img/img2.jpg">
                <img src="img/img2.jpg" alt="">
                <p>Expiermentation with texture and color.</p>
              </a>  
            </li>
            <li>
              <a href="img/img6.jpg">
                <img src="img/img6.jpg" alt="">
                <p>Expiermentation with texture and color.</p>
              </a>  
            </li>
            <li>
              <a href="img/img9.jpg">
                <img src="img/img9.jpg" alt="">
                <p>Expiermentation with texture and color.</p>
              </a>  
            </li>
            <li>
              <a href="img/img12.jpg">
                <img src="img/img12.jpg" alt="">
                <p>Expiermentation with texture and color.</p>
              </a>  
            </li>
          </ul>

        </section>
        <footer>
          <a href="http://twitter.com/kitomiddleton"><img src="img/twitter-wrap.png" alt="twitter" class="social-icon"></a>
          <a href="http://twitter.com/kitomiddleton"><img src="img/facebook-wrap.png" alt="facebook" class="social-icon"></a>
          <p>Ā© 2016 Kito Middleton.</p>
        </footer>
      </div>

</body>
</html> ```

1 Answer

Seth Kroger
Seth Kroger
56,413 Points

In your anchor tags, the href for all of them is pointing to "index.html", which means all the links will take you back to the index page. If you want to point the links to another page, you need to change it to the name of the page's html file in href.

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