niche Posted June 17, 2010 Share Posted June 17, 2010 I don't understand what's meant by an anchor URL as in: An anchor URL - points to an anchor within a page (like href="#top") (http://www.w3schools.com/tags/att_a_href.asp).What's an anchor and how is it used?Thanks Link to comment Share on other sites More sharing options...
Synook Posted June 17, 2010 Share Posted June 17, 2010 An anchor is an element defined by the <a> tag. If you give an anchor an ID (or a name, for older browsers), you can set up another anchor to link to that part of the page using the hash symbol. For example, if you had: <a id="anchor"></a> Then you link to the part of the page with that tag using: <a href="#anchor">Click here</a> Link to comment Share on other sites More sharing options...
niche Posted June 17, 2010 Author Share Posted June 17, 2010 Sounds like that might come in handy if you have a long page and want to move around quickly as in a page has 50 chapters and each chapter is an anchor where navigation linked to 50 different anchors .Right ? Link to comment Share on other sites More sharing options...
Synook Posted June 17, 2010 Share Posted June 17, 2010 Yes... but you may want to just split that up into multiple pages anyway, or else loading times will be horrible. Link to comment Share on other sites More sharing options...
niche Posted June 17, 2010 Author Share Posted June 17, 2010 Thanks for your help Synook. Link to comment Share on other sites More sharing options...
thescientist Posted June 17, 2010 Share Posted June 17, 2010 you don't have to necessarily use ID on an <a> tag. Any element can be given an ID, and thus linked inpage. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.