1

我有以下代码,无法在滑块上添加自动播放。谁能帮我这个?

$('#front-slides').slides({
        preload: true,
        generateNextPrev: false,
        slideSpeed: 500,
        animationStart: function(current){
            $slideCaption = $(".slides_container div.slide:eq("+ (current-1) +") .caption").text();
            $("#headline h6").text($slideCaption);

            if($slideCaption != ''){
                $("#headline").stop().hide().slideDown(600);
            }else{
                $("#headline").hide();
            }
        }
    });
4

2 回答 2

1

只需在 slideSpeed 下添加以下行:500,

    play: 5000,
    pause: 2500,
于 2013-10-26T08:11:16.627 回答
0
  $(function() { 
      $(".slider").jCarouselLite({
      auto:500,
      speed:800,
      btnNext: ".next",                     
      btnPrev: ".prev",                     
      visible: 5                 
     });             
});
于 2013-10-26T08:15:08.050 回答