const navitems = ` `; // {/* // // */} $(function() { setTimeout(function() { $('#page-side-nav #topNav ul').html(''); $('#page-side-nav #topNav ul').append($(navitems)); $('#page-side-nav #topNav ul li').show(); }, 1000) $('select[name="session-register-industry[11533]"]').change(function() { if ($(this).val() == '26') { $('input[name="session-register-custom2"]').show(); } else { $('input[name="session-register-custom2"]').hide().val(''); } }).change(); // $('input[name="session-register-custom4[]"]').change(function() { // if (($(this).val() == '其他 (請填寫)') && ($(this).prop('checked'))) { // $('input[name="session-register-custom10"]').show(); // } else { // $('input[name="session-register-custom10"]').hide().val(''); // } // }).change(); // $('input[name="session-register-custom5[]"]').change(function() { // if (($(this).val() == '其他 (請填寫)') && ($(this).prop('checked'))) { // $('input[name="session-register-custom12"]').show(); // } else { // $('input[name="session-register-custom12"]').hide().val(''); // } // }).change(); // $('input[name="session-register-custom5[]"]').change(function() { // if (($(this).val() == 'VMware VCPP 合作夥伴的公有雲服務') && ($(this).prop('checked'))) { // $('input[name="session-register-custom11"]').show(); // } else { // $('input[name="session-register-custom11"]').hide().val(''); // } // }).change(); // $('input[name="session-register-custom6[]"]').change(function() { // if (($(this).val() == '其他 (請填寫)') && ($(this).prop('checked'))) { // $('input[name="session-register-custom13"]').show(); // } else { // $('input[name="session-register-custom13"]').hide().val(''); // } // }).change(); }); function goScroll(target) { var target_top = $(target).offset().top; var header_height = $('#nav').height(); var sTop = target_top - header_height; $("html, body").stop().animate({ scrollTop: sTop }, 400); } $(function() { location.hash && (function() { goScroll(location.hash); }()); $('.goScroll').click(function() { var target = $(this).attr("href"); goScroll(target); return false; }); // var tab_index = 0; // setInterval(function() { // tab_index = (tab_index + 1) % 4; // $('.nav.nav-tabs').find('a').eq(tab_index).click(); // }, 6000); }); // Speaker $(".openclose").on('click', function() { if (!$(this).hasClass('open')) { $(this).addClass('open') $(this).html(' - 收合課程介紹'); $(this).parent().find('.openclose_block').slideDown(500); } else { $(this).removeClass('open') $(this).html(' + 展開課程介紹'); $(this).parent().find('.openclose_block').slideUp(500); } })