平滑的类似锚点的菜单定位,页面URL不变化
XML/HTML Code
- <header role="banner">
- <div class="container">
- <ul class="nav nav-main">
- <li data-scrollto="daohangcaidan">导航菜单</li>
- <li data-scrollto="basic">TAB标签</li>
- <li data-scrollto="biaodan">表单</li>
- </ul>
- </div>
- </header>
XML/HTML Code
- <section class="shaded">
- <div class="container" id="daohangcaidan">
- </div>
- </section>
原文地址:http://www.freejs.net/article_jquerywenzi_751.html