To link to a named anchor, you need another anchor tag, only this one should be a source anchor, not a destination anchor. In the href attribute of the source anchor, type a number sign (#) followed by the name of the anchor to which you want to link, like this: <ol> <li><a href="#question01">What is the meaning of life?</a></li> <li><a href="#question02">What is the meaning of money?</a></li> <li><a href="#question03">What is the meaning of time?</a></li> </ol> These anchor tags appear as regular hyperlinks in the browser. That's because they are regular hyperlinks. The only difference is that they go to named anchors on the same page, not to the top of some other page.
What happens if you want to link to a named anchor that exists on some other page? Not a problem. Simply tack the named-anchor nomenclature to the end of the path, like this: <a href="../movies/movies.htm#newrelases">New Releases</a> This hybrid path finds the page movies.htm and then jumps to the newreleases named anchor on this page.
|