0
如何在單擊鏈接後使用scrollify庫將網頁轉換爲頁面的特定部分。在鏈接上使用Scrollify
<ul class="nav navbar-nav">
<li><a href="#1" class="link">this is a link</a></li>
<li><a href="#2" class="link">this is another link</a></li>
<li><a href="#3" class="link">and another link</a></li>
</ul>
每一個這些點擊都會將用戶發送到下面顯示的網頁的某個部分。現在沒有滾動,沒有軟轉換到每個部分。
<h3 class="season" id="1"><span class="seasontext">SS17</span></h3>
<h3 class="season" id="2"><span class="seasontext">SS17</span></h3>
<h3 class="season" id="3"><span class="seasontext">SS17</span></h3>
這是scrollify模板,但我不太清楚如何單獨訪問鏈接以及如何使用轉換。
$.scrollify({
section : "link",
interstitialSection : "",
easing: "easeOutExpo",
scrollSpeed: 1100,
offset : 0,
scrollbars: true,
standardScrollElements: "",
setHeights: true,
overflowScroll: true,
updateHash: true,
touchScroll:true,
before:function() {},
after:function() {},
afterResize:function() {},
afterRender:function() {}
});
$.scrollify.move("#season");