2
我目前使用的是slidesjs.com滑塊,我想這樣做,當我點擊滑塊之外的鏈接時,它滑動到當前幻燈片,例如,點擊滑動一個鏈接(#1),並滑動滑動滑塊內的一個(#1)。這是我的編碼任何幫助將不勝感激。jQuery滑塊 - Slider外部的滑動鏈接
$(function(){
// Set starting slide to 1
var startSlide = 1;
// Get slide number if it exists
if (window.location.hash) {
startSlide = window.location.hash.replace('#','');
}
// Initialize Slides
$('#passion_slider').slides({
autoHeight: true,
// Get the starting slide
start: startSlide,
animationComplete: function(current){
// Set the slide number as a hash
window.location.hash = '#' + current;
}
});
});
該編碼僅將您帶到第一張幻燈片。 – Delete
看到鏈接,看看我的意思http://www.media21a.co.uk/clientlogin/passionradio/ – Delete
此外,當我點擊幻燈片內,它也改變,即時只是尋找它改變幻燈片一旦點擊導航鏈接外滑塊。如果你知道這個問題的解決方案,這將是非常感激的兄弟。 – Delete