Posts Tagged ‘anchor’

HTML Anchor

The Anchor has two important functions in HTML. First it is the main method for interlinking HTML documents and non-HTML media using the href attribute. It can also be used to jump to a location within a HTML document using the id attribute.

1
<a href="http://www.bbc.co.uk">BBC Online</a>

BBC Online

The hash # symbol can be used to jump to any element with an ID attribute. The link below will jump to to the top of the current page, which has an attribute id=”header”.

1
<a href="#header">Jump to Page Header</a>

Jump to Page Header