<a href="#test">点击锚</a>
...
<a name="test">到标记</a>
这是最简单的锚标记的方式,在网页中可能由于篇幅过大所以很长,那么想回到某个位置就可以用这种方式定位。
还有种是用javascript
<script>
function move()
{
location.hash="#there";
}
</script>
<div onclick="move()">GO</div>
...
<div id="there">there</div>
利用location.hash="#there";
定位,不过明显没有a来的方便,不知道这个hash还有没有其他的用处