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 HTML Basics Going Further with HTML Links and Paths Challenge

How do you set "portfolio" link to navigate to the section of the page with id portfolio

ive tried to put" /#portofolio" in the link but there still seems to be an issue

index.html
<!DOCTYPE html> 
<html>
  <head>
    <title>Portfolio Page</title>
  </head>
  <body>
    <img src="../img/logo.png" alt="Site logo">
    <ul>
      <li><a href="/">Home</a></li>
      <li><a href="/#portfolio">My Portfolio</a></li>               
    </ul>
    <div id="portfolio">My Portfolio</div>
  </body>
</html>

2 Answers

Hello there,

If your Portfolio section is inside the same page, all you need to do is to remove the "/" from "/#portfolio", as it should be just "#portfolio".

The "id=portfolio" at the bottom of the page has been set correctly.

Let me know if that works!

thanks man

/#portfolio inside the link to navigate to the id portfolio