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 Problem

I am sorry but guys are not helping I got stuck in the href how to link the picture to. the top I ask for help but no

the problem was when I was trying to write that href how to link the picture to the top I message twice but no answer from u guys

1 Answer

Sam Natale
Sam Natale
1,526 Points

Please link code so we can help out more.

I think you are asking how to make a href to link to the top of the page? If so you need to do the following:

In your header element or your h1 add the following:

<h1 id="top">Example H1</h1>

Then add the following to your link:

<p><a href="#top">Link Example</a></p>

The way it works in my example is that you are adding the id attribute of "top" to the h1 element, this means that its reference will be #top, you can then use this reference in href to link to #top.

Hope this is the solution you was looking for, I struggled to understand your question originally.