2012-08-22 3 views
0

3 개의 배너와 3 개의 배너가있는 jquery주기가 있습니다.jquery주기 중지주기 링크를 클릭했을 때

<div id="adverts" style="position: relative; width: 960px; height: 246px; "> 
    <img class="im" src="/uploads/ssp/album_2/image_59.jpg" alt="open" data-id="http://co.uk/content/2/207/eis-fund-3.html" height="246" width="960" style="position: absolute; top: 0px; left: 0px; display: block; z-index: 4; opacity: 1; width: 960px; height: 246px; ">  
    <img class="im" src="/uploads/ssp/album_2/image_60.jpg" alt="extended" data-id="" height="246" width="960" style="position: absolute; top: 0px; left: 0px; display: none; z-index: 3; opacity: 0; width: 960px; height: 246px; "> 
    <img class="im" src="/uploads/ssp/album_2/image_61.jpg" alt="Welcome" data-id="" height="246" width="960" style="position: absolute; top: 0px; left: 0px; display: none; z-index: 3; opacity: 0; width: 960px; height: 246px; "> 
</div> 

<ul id="nav"> 
<li class=""><a href="#">open</a></li> 
<li class=""><a href="#">extended</a></li> 
<li class="activeSlide"><a href="#">Welcome</a></li></ul> 

$(document).ready(function() { 

    $('#adverts').cycle({ 
     fx: 'fade', 
     pager: '#nav', 
     speed: 300, 
     // callback fn that creates a thumbnail to use as pager anchor 
     pagerAnchorBuilder: function (idx, slide) { 
      return '<li><a href="#">' + slide.alt + '</a></li>'; 
     } 
    }); 

    $(".im").click(function() { 
     var url = $(this).attr('data-id'); 
     window.location = url; 
    }); 

}); 

현재 링크를 클릭하면 올바른 배너로 이동합니다. 그러나 나는 그것을 멈추고 사용자가 다른 배너를 클릭 할 때만 변경하거나 클릭이 발생한 후 3 초마다 10 초로 변경하는 속도를 높이시겠습니까?

RGDS 우지

당신은 stop 또는 pause 명령을 조사 할 수 있습니다

답변

관련 문제