jquery slider yardım
3
●497
- 13-08-2013, 03:14:44Jquery tutorial lerinden yardım alarak bu işini halledebilirdin diye düşünüyorum.
Ufak örnek gösterebileceğim bir kod mesela
$('#slideshow').cycle({ fx: 'scrollHorz', timeout: 2000, autostop: 1, end: function() { alert('The slideshow has ended.'); } });Burada slayt bitince ekrana uyarı veriyor.
Bu kodu editleyerek işini görebileceğini düşünüyorum.
$(window).load(function(){ animate_spotlight(); }); function animate_spotlight(){ var $current_spot = $('#spotlight span.active') var pos = $current_spot.next().position().left; $('#spotlight').stop().animate({ left : '-' + pos + 'px' }, {easing : 'linear', duration : 3000, complete : function(){ $current_spot.next().addClass('active'); // Fetch new object $current_spot.appendTo('#spotlight'); // Put the old object last in #spotlight elem. $('#spotlight').css({left : 0 + 'px'}) // Reset the position $current_spot.removeClass('active'); // Removes active class of the old elem. animate_spotlight(); // Loop }}); }Kaynak: http://stackoverflow.com/questions/1...er-speed-issue