$(function(){ /* slen =$(".study_lists ul li").length; if(slen>3){ wPer = 424; $(".study_lists ul li:last").prependTo(".study_lists ul"); $(".study_lists ul").css("margin-left",-wPer+"px"); $(".study_next").click(function(){ event.stopPropagation() $(".study_lists ul li:first").clone().appendTo(".study_lists ul"); $(".study_lists ul").animate({marginLeft:"-="+wPer+"px"},500,function(){ $(".study_lists ul li:first").appendTo(".study_lists ul"); $(".study_lists ul li:last").remove(); $(".study_lists ul").css("margin-left",-wPer+"px"); }) }); $(".study_prev").click(function(){ event.stopPropagation() $(".study_lists ul").animate({marginLeft:"+="+wPer+"px"},500,function(){ $(".study_lists ul li:last").prependTo(".study_lists ul"); $(".study_lists ul").css("margin-left",-wPer+"px"); }); }); }else{ } */ $(".card_tabs ul li").click(function(){ tabno = $(".card_tabs ul li").index($(this)); $(this).addClass("on").siblings().removeClass("on"); $(".cardcons").hide(); $(".cardcons:eq("+tabno+")").show(); }) clength1 = $(".cl1>ul>li").length; if(clength1<5){ $(".cbbs1_prev").hide(); $(".cbbs1_next").hide(); }else{ $(".cbbs1_prev").show(); $(".cbbs1_next").show(); $(".cl1>ul>li:last").prependTo(".cl1>ul"); $(".cl1>ul").css("margin-left",-332+"px"); } clength2 = $(".cl2>ul>li").length; if(clength2<5){ $(".cbbs1_prev").hide(); $(".cbbs1_next").hide(); }else{ $(".cbbs1_prev").show(); $(".cbbs1_next").show(); $(".cl2>ul>li:last").prependTo(".cl2>ul"); $(".cl2>ul").css("margin-left",-332+"px"); } clength3= $(".cl3>ul>li").length; if(clength3<5){ $(".cbbs1_prev").hide(); $(".cbbs1_next").hide(); }else{ $(".cbbs1_prev").show(); $(".cbbs1_next").show(); $(".cl3>ul>li:last").prependTo(".cl3>ul"); $(".cl3>ul").css("margin-left",-332+"px"); } $(".cbbsnext").click(function(event){ event.stopPropagation() $(".cl1>ul:not(:animated)").animate({marginLeft:"-="+332+"px"},500,function(){ $(".cl1>ul>li:first").clone().appendTo(".cl1>ul"); $(".cl1>ul>li:first").appendTo(".cl1>ul"); $(".cl1>ul>li:last").remove(); $(".cl1>ul").css("margin-left",-332+"px"); }) }); $(".cbbsprev").click(function(event){ event.stopPropagation() $(".cl1>ul:not(:animated)").animate({marginLeft:"+="+332+"px"},500,function(){ $(".cl1>ul>li:last").prependTo(".cl1>ul"); $(".cl1>ul").css("margin-left",-332+"px"); }); }); $(".cbbsnext2").click(function(event){ event.stopPropagation() $(".cl2>ul:not(:animated)").animate({marginLeft:"-="+332+"px"},500,function(){ $(".cl2>ul>li:first").clone().appendTo(".cl2>ul"); $(".cl2>ul>li:first").appendTo(".cl2>ul"); $(".cl2>ul>li:last").remove(); $(".cl2>ul").css("margin-left",-332+"px"); }) }); $(".cbbsprev2").click(function(event){ event.stopPropagation() $(".cl2>ul:not(:animated)").animate({marginLeft:"+="+332+"px"},500,function(){ $(".cl2>ul>li:last").prependTo(".cl2>ul"); $(".cl2>ul").css("margin-left",-332+"px"); }); }); $(".cbbsnext3").click(function(event){ event.stopPropagation() $(".cl3>ul:not(:animated)").animate({marginLeft:"-="+332+"px"},500,function(){ $(".cl3>ul>li:first").clone().appendTo(".cl3>ul"); $(".cl3>ul>li:first").appendTo(".cl3>ul"); $(".cl3>ul>li:last").remove(); $(".cl3>ul").css("margin-left",-332+"px"); }) }); $(".cbbsprev3").click(function(event){ event.stopPropagation() $(".cl3>ul:not(:animated)").animate({marginLeft:"+="+332+"px"},500,function(){ $(".cl3>ul>li:last").prependTo(".cl3>ul"); $(".cl3>ul").css("margin-left",-332+"px"); }); }); $(".main_btm_bbs_tabs ul li").click(function(){ tabno = $(".main_btm_bbs_tabs ul li").index($(this)); $(this).addClass("on").siblings().removeClass("on"); $(".bbs_tabcon").hide(); $(".bbs_tabcon:eq("+tabno+")").show(); }) })