테스트 사이트 - 개발 중인 베타 버전입니다

제이쿼리 질문좀 드리겠습니다. 채택완료

7년 전 조회 2,271

안녕하세요 질문좀 드리겠습니다

 

탭메뉴 안에 스와이프 슬라이드를 넣은건데 

스와이프 슬라이드가 작동을 안합니다 ㅠㅠ

혹시 뭐떄문인지 알려주시면 감사하겠습니다 

 

</p>

<p><script>

 $(function () {</p>

<p>    $(".tab_content").hide();

    $(".tab_content:first").show();</p>

<p>    $("ul.tabs li").click(function () {

        $("ul.tabs li").removeClass("active").css("color", "#797979");

        //$(this).addClass("active").css({"color": "darkred","font-weight": "bolder"});

        $(this).addClass("active").css("color", "#fff");

        $(".tab_content").hide()

        var activeTab = $(this).attr("rel");

        $("#" + activeTab).fadeIn()

    });

});</p>

<p> var swiper = new Swiper('.swiper-container', {

      spaceBetween: 30,

      centeredSlides: true,

      autoplay: {

        delay: 2500,

        disableOnInteraction: false,

      },

      pagination: {

        el: '.swiper-pagination',

        clickable: true,

      },

      navigation: {

        nextEl: '.swiper-button-next',

        prevEl: '.swiper-button-prev',

      },

    });

</script></p>

<p> </p>

<p>

댓글을 작성하려면 로그인이 필요합니다.

답변 2개

채택된 답변
+20 포인트

9번째줄, 11번째줄 끝에 세미콜론(;)빠졌어요오오오~~~~

로그인 후 평가할 수 있습니다

댓글을 작성하려면 로그인이 필요합니다.

$("#" + activeTab).fadeIn() => $( '.tab_content' ).eq( $(this).index() ).fadeIn()

로그인 후 평가할 수 있습니다

답변에 대한 댓글 1개

제가 초보라서 그런데 어떻게 하시라는거죠 ㅠㅠ?

댓글을 작성하려면 로그인이 필요합니다.

답변을 작성하려면 로그인이 필요합니다.

로그인

전체 질문 목록

🐛 버그신고