<a herf="#标记1">跳到第一部分 </a> 页面跳转到如下的锚标记所在的位置
<a name="标记1"></a>许多网站都有 Top 的功能,就是在顶部放一个锚标记

解决方案 »

  1.   

    就是锚嘛
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html>   
      <head>   
      <script   type="text/javascript">    </script>   
      </head>   
      <body>   
    <a name='top'></a>
    <input type='text' readonly id='hehe'>
    <input type='button' value='test' onclick='alert(document.getElementById("hehe").readOnly);'>
    <div style='height:1200px; width:600px; background-color:#f4f4f4;'></div>
    <a href='#top'>回到顶部</a>
      </body>   
      </html>