Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

HTML

Claire Fontaine
Claire Fontaine
1,955 Points

Challenge question for using "id" tag as a link keeps rejecting my answer.

Index Page Navigation list . . . . .

<ul> <li><a href="/#portfolio">Portfolio</a></li> </ul> . . . . . Section further down on the page. <h1 id="portfolio">My Portfolio</h1>


I'm using the same coding as the illustrated in the "hints" part of the question. I can't see for the life of me what the problem is. I've got over the videos and they say the same thing. Am I mis interpreting the question or is this is a bug?

Steven Parker
Steven Parker
220,416 Points

Can you provide a link to the challenge page?

2 Answers

Steven Parker
Steven Parker
220,416 Points

Without trying the actual challenge, I suspect the issue is caused by the slash preceding the # and name. A slash is only used for an absolute reference but this one should probably be relative.

Claire Fontaine
Claire Fontaine
1,955 Points

Thanks Steve, you are correct. I was getting confused with all those forward slashes and dots.

Correct response is: <ul> <li><a href="#portfolio">Portfolio</a></li> </ul>