var NmFooter = { Init : function() { return true; }, Show : function() { var nmFooterBody = document.getElementsByName('NmFooter'); if ( nmFooterBody == null || nmFooterBody.length == 0 ) { nmFooterBody = document.body; } else { nmFooterBody = nmFooterBody[0]; } /* Header */ var footer = document.createElement( 'footer' ); footer.setAttribute( 'id', 'footer' ); footer.setAttribute( 'class', 'footer' ); var htmlFooter = '
'+ '' + '
© Netmarble Corp. All Rights Reserved
' + '
'; footer.innerHTML = (htmlFooter); document.getElementsByClassName("wrap")[0].appendChild(footer); //nmFooterBody.insertBefore( footer,nmFooterBody.firstChild ); } } if ( NmFooter.Init() ) { NmFooter.Show(); } /* main slide */ function uiSlide1(el) { var obj = $(el); require(['slidesjs'], function(s) { obj.slidesjs({ width: obj.innerWidth(), height: obj.innerHeight(), play: { effect: "slide", interval: 5000, auto: true, hoverPause: true }, effect: { fade: { speed:500 } } }); }); } function uiSlide2(el) { var obj = $(el); require(['slidesjs'], function(s) { obj.slidesjs({ width: obj.innerWidth(), height: obj.innerHeight(), effect: { fade: { speed:500 } } }); }); } function uiSlide3(el) { var obj = $(el); var tab = arguments[1]; require(['slidesjs'], function(s) { obj.slidesjs({ width: obj.innerWidth(), height: obj.innerHeight(), effect: { fade: { speed:500 } }, callback: { complete: function(idx) { if(tab) { $(tab).find('li').removeClass('on').eq(idx-1).addClass('on'); } } } }); }); } $(document).ready(function() { uiSlide1("#uMainSlide"); uiSlide2("#uGameSlide"); uiSlide2("#uSlide4"); uiSlide2("#uSlide5"); uiSlide3("#uSlide3", "#uTabCharacter"); document.cookie = "lang="; document.cookie = "lang=ko"; }); var tab_char_a = $("#uTabCharacter a"); tab_char_a.on("click", function(e){ e.preventDefault(); $("#uSlide3 .slidesjs-pagination a").eq(tab_char_a.index($(this))).trigger("click"); }); $(window).resize(function() { changeDocumentSize(); }); function changeDocumentSize() { $(".m_prom .slidesjs-container,.m_prom .slidesjs-control, .m_prom .slide").css({ 'width':jQuery('.m_prom .slide_wrap').width() }); $(".m_game .slidesjs-container,.m_game .slidesjs-control, .m_game .slide").css({ 'width':jQuery('.m_game .slide_wrap').width() }); $(".facility_bx .slidesjs-container,.facility_bx .slidesjs-control, .facility_bx .slide").css({ 'width':jQuery('.facility_bx .slide_wrap').width() }); $(".fac_lst_bx .slidesjs-container,.fac_lst_bx .slidesjs-control, .fac_lst_bx .slide").css({ 'width':jQuery('.fac_lst_bx .slide_wrap').width() }); } /* side menu */ $("#uBtnMenu").click(function(){ $("#uSnbMenu").animate({"margin-left":"0"},300); $(".wrap").append('
'); $(".uPanelDimmed").css({ "position":"absolute", "top":"0", "left":"0", "zIndex": "1001", "width": "100%", "height": "100%", "background-color": "#000", "cursor":"pointer", "opacity": "0.7" }); $(".wrap").append('닫기').on('click', '.uPanelClose', function(){ $("#uSnbMenu").animate({"margin-left":"-290px"},300); $(".uPanelDimmed").remove(); $(".uPanelClose").remove(); }); $("#uSnbMenu").css({'height':$(document).height()+"px"}); }); $(".btnSnbClose").click(function(){ $("#uSnbMenu").animate({"margin-left":"-290px"},300); $(".uPanelDimmed").remove(); $(".uPanelClose").remove(); }); /* SNB */ var depth1, depth2=''; var temp=true; function navi_on(d1,d2){ depth1 = d1; depth2 = d2; $('#divSnb > li > h2 > a').bind('click', function(){ var _this = $(this); $('#divSnb > li > h2').removeClass('selected'); _this.parent().addClass('selected'); $('#divSnb > li > .s_menu').hide(0); temp=false; _this.parent().next().slideDown(200,function(){temp=true}); }); $('#divContents').bind('mouseenter', function(){ if (temp==true){ $('#divSnb > li > h2').removeClass('selected'); $('#divSnb > li > .s_menu').fadeOut(200); } }); if (depth1 != undefined){ $('#divContents').unbind('mouseenter'); function uiSubNavi(){ $('#divSnb > li > h2').removeClass('selected'); $('#divSnb .'+depth1).find('h2').addClass('selected'); $('#divSnb > li > .s_menu').hide(0); $('#divSnb .'+depth1+' .s_menu').show(); $('#divSnb > li > .s_menu > li').removeClass('on'); $('#divSnb > li > .s_menu > li a.'+depth2).parent().addClass('on'); } uiSubNavi(); $('#divContents').bind('mouseenter', function() { uiSubNavi(); }); } } function goPc() { document.cookie = "fromMobile=true; domain=netmarble.com"; location.href="https://company.netmarble.com"; } //nav function uiNavOn() { var snb_tx = $('.title > h3 > strong').text(); $('.sel_lst ul li a').each(function() { if($(this).text() === snb_tx) $(this).parent().addClass('on'); }); };