mirror of
https://github.com/3lswear/webserv.git
synced 2025-10-29 13:27:59 +03:00
tomato and besmart src
This commit is contained in:
26
www/def/besmart/js/func.js
Normal file
26
www/def/besmart/js/func.js
Normal file
@@ -0,0 +1,26 @@
|
||||
|
||||
$(document).ready(function() {
|
||||
$('.slider').jcarousel( {
|
||||
initCallback: slider_initCallback,
|
||||
itemFirstInCallback: slider_firstInCallback,
|
||||
scroll: 1,
|
||||
auto: 5,
|
||||
wrap: 'both',
|
||||
// This tells jCarousel NOT to autobuild prev/next buttons
|
||||
buttonNextHTML: null,
|
||||
buttonPrevHTML: null
|
||||
});
|
||||
});
|
||||
|
||||
function slider_initCallback (carousel) {
|
||||
|
||||
$('.slider-nav a').bind('click', function() {
|
||||
carousel.scroll($.jcarousel.intval($(this).text()));
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
||||
function slider_firstInCallback(carousel, item, idx, state) {
|
||||
$('.slider-nav a').removeClass('active');
|
||||
$('.slider-nav a').eq(idx-1).addClass('active');
|
||||
}
|
||||
Reference in New Issue
Block a user