我想知道如何找到類似於Flickr's homepage的東西?我在談論靜態背景下的透明幻燈片。到目前爲止,我知道如何使用靜態背景並瀏覽透明DIV,但我不知道幻燈片「系統」是如何工作的。我如何獲得類似於Flickr網站的內容?
謝謝。
我想知道如何找到類似於Flickr's homepage的東西?我在談論靜態背景下的透明幻燈片。到目前爲止,我知道如何使用靜態背景並瀏覽透明DIV,但我不知道幻燈片「系統」是如何工作的。我如何獲得類似於Flickr網站的內容?
謝謝。
只需製作一個普通網站,但在頁面中添加一個auto scroller
腳本即可完成此操作。
按鈕上下往上只是一些<a href="#id"></a>
標籤,其ID爲鏈接。通常情況下,你會立即在該ID,但與你的auto scroller
你會順利。
這裏是一個auto scroller
,我總是用我的網站(an example by pressing in the menu):
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script>
$(function() {
$('a[href*=#]:not([href=#])').click(function() {
if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) {
var target = $(this.hash);
target = target.length ? target : $('[name=' + this.hash.slice(1) +']');
if (target.length) {
$('html,body').animate({
scrollTop: target.offset().top
}, 2000 /*<-- This is your time for every scroll in miliseconds*/);
return false;
}
}
});
});
</script>
我希望這有助於你。
你應該看看Parralax滾動,也scrollTo那裏有好的圖書館。 – craigie2204
爲什麼some1會降低這一點? @ craigie2204謝謝!我一定會給他們一個嘗試。, – Raulnd
[fullPage.js](http://alvarotrigo.com/fullPage/)是你的答案。只需使用插件選項'scrollBar:true'即可。 – Alvaro