$(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.box_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.box_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_spa_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.box_spa_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_rooms_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.box_rooms_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_type_a_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.cnt_type_a_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_type_b_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.cnt_type_b_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_type_c_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.cnt_type_c_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_type_d_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.cnt_type_d_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_dinner_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.cnt_dinner_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.cnt_kaz_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.cnt_kaz_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.spaleft_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.box_spaleft_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); }); $(function(){ var cT = 2000, sT = 3000; var index = 0, $img = $('.sparight_slide').children('.slide'), imgLen = $img.length; $img.not(':first').css('opacity','0'); for (var i=0; i'); } var $tN = $('.box_sparight_thum li'); $tN.first().addClass('active'); $tN.click(function(){ $img.stop(); clearInterval(slides); $(this).addClass('active').siblings().removeClass('active'); var number = $(this).index(), $choiceImg = $img.eq(number); index = (number) % imgLen; $choiceImg.siblings().animate({opacity:0},cT); $choiceImg.animate({opacity:1},cT); start(); }); function start(){ slides = setInterval(function(){ var next = (index +1) % imgLen; $tN.removeClass('active').eq(next).addClass('active'); $img.eq(index).animate({opacity:0},cT); $img.eq(next).animate({opacity:1},cT); index = next; },sT + cT); }; start(); });