1/** 2 * ìì§ì´ë ë°°ë Jquery Plug-in 3 * @author cafe24 4 */ 5 6(function($){ 7 8 $.fn.floatBanner = function(options) { 9 options = $.extend({}, $.fn.floatBanner.defaults , options); 10 11 return this.each(function() { 12 var aPosition = $(this).position(); 13 var jbOffset = $(this).offset(); 14 var node = this; 15 16 $(window).scroll(function() { 17 var _top = $(document).scrollTop(); 18 _top = (aPosition.top < _top) ? _top : aPosition.top + 100; 19 20 setTimeout(function () { 21 var newinit = $(document).scrollTop(); 22 23 if ( newinit > jbOffset.top ) { 24 _top -= jbOffset.top; 25 var container_height = $("#wrap").height(); 26 var quick_height = $(node).height(); 27 var cul = container_height - quick_height; 28 if(_top > cul){ 29 _top = cul; 30 } 31 }else { 32 _top = 0; 33 } 34 35 $(node).stop().animate({top: _top}, options.animate); 36 }, options.delay); 37 }); 38 }); 39 }; 40 41 $.fn.floatBanner.defaults = { 42 'animate' : 500, 43 'delay' : 500 44 }; 45 46})(jQuery); 47 48/** 49 * 문ì 구ëí ìì 50 */ 51$(document).ready(function(){ 52 $('#banner:visible, #quick:visible').floatBanner(); 53 54 //placeholder 55 $(".ePlaceholder input, .ePlaceholder textarea").each(function(i){ 56 var placeholderName = $(this).parents().attr('title'); 57 $(this).attr("placeholder", placeholderName); 58 }); 59 /* placeholder ie8, ie9 */ 60 $.fn.extend({ 61 placeholder : function() { 62 //IE 8 ë²ì ìë hasPlaceholderSupport() ê°ì´ false를 ë¦¬í´ 63 if (hasPlaceholderSupport() === true) { 64 return this; 65 } 66 //hasPlaceholderSupport() ê°ì´ false ì¼ ê²½ì° ìë ì½ë를 ì¤í 67 return this.each(function(){ 68 var findThis = $(this); 69 var sPlaceholder = findThis.attr('placeholder'); 70 if ( ! sPlaceholder) { 71 return; 72 } 73 findThis.wrap('<label class="ePlaceholder" />'); 74 var sDisplayPlaceHolder = $(this).val() ? ' style="display:none;"' : ''; 75 findThis.before('<span' + sDisplayPlaceHolder + '>' + sPlaceholder + '</span>'); 76 this.onpropertychange = function(e){ 77 e = event || e; 78 if (e.propertyName == 'value') { 79 $(this).trigger('focusout'); 80 } 81 }; 82 //ê³µíµ class 83 var agent = navigator.userAgent.toLowerCase(); 84 if (agent.indexOf("msie") != -1) { 85 $(".ePlaceholder").css({"position":"relative"}); 86 $(".ePlaceholder span").css({"position":"absolute", "padding":"0 4px", "color":"#878787"}); 87 $(".ePlaceholder label").css({"padding":"0"}); 88 } 89 }); 90 } 91 }); 92 93 $(':input[placeholder]').placeholder(); //placeholder() í¨ì를 í¸ì¶ 94 95 //í´ë¦íë©´ placeholder ì¨ê¹ 96 $('body').delegate('.ePlaceholder span', 'click', function(){ 97 $(this).hide(); 98 }); 99 100 //inputì°½ í¬ì»¤ì¤ ì¸ ì¼ë placeholder ì¨ê¹ 101 $('body').delegate('.ePlaceholder :input', 'focusin', function(){ 102 $(this).prev('span').hide(); 103 }); 104 105 //inputì°½ í¬ì»¤ì¤ ìì ì¼ë value ê° true ì´ë©´ ì¨ê¹, false ì´ë©´ ë³´ì¬ì§ 106 $('body').delegate('.ePlaceholder :input', 'focusout', function(){ 107 if (this.value) { 108 $(this).prev('span').hide(); 109 } else { 110 $(this).prev('span').show(); 111 } 112 }); 113 114 //inputì placeholderê° ì§ìì´ ëë©´ true를 ìëë©´ false를 리í´ê°ì¼ë¡ ëì ¸ì¤ 115 function hasPlaceholderSupport() { 116 if ('placeholder' in document.createElement('input')) { 117 return true; 118 } else { 119 return false;
120 } 121 } 122 123 ////// ìì§ ì¶ê° ìì¤ 124 125 126 // ë°°ëê´ë¦¬ img ë§ì°ì¤ì¤ë²ì íì´í ë ¸ì¶ ì·¨ì 127 $(".xans-bannermanage2 a img").attr("title",""); 128 129 // ë°ì¤ ì¤íì¼ ì¹´í ê³ ë¦¬ ì¤ ë´ê° ì íí ì¹´í ê³ ë¦¬ì seleted í´ëì¤ ì½ì í기 - company, shop 130 var li = $('.box_menu > ul > li'); 131 li.find('a').each(function(i, e){ 132 var a_link = $(this).attr('href'); 133 if(0 <= location.href.indexOf(a_link)){ 134 $(this).parent().addClass('selected'); 135 } 136 }); 137 138 // BEST ìí ë²í¸ 139 var bestLi = $(".xans-product-listrecommend > .prdList > li"); 140 bestLi.each(function(i, e){ 141 var no = $(this).index() + 1; 142 $(this).find('.best_cnt i').text(no); 143 }); 144 145}); 146 147/** 148 * ì¸ë¤ì¼ ì´ë¯¸ì§ ìë°ì¼ê²½ì° ê¸°ë³¸ê° ì¤ì 149 */ 150$(window).load(function() { 151 $("img.thumb,img.ThumbImage,img.BigImage").each(function($i,$item){ 152 var $img = new Image(); 153 $img.onerror = function () { 154 $item.src="//img.echosting.cafe24.com/thumb/img_product_big.gif"; 155 } 156 $img.src = this.src; 157 }); 158}); 159 160/* í¤ë */ 161$(window).ready(function(){ 162 var fix = $("#header").offset().top; 163 $(window).scroll(function(){ 164 if( $(window).scrollTop() > fix + $(window).height()-65 ) { 165 $('#header #headerBottom').addClass('fixedstyle'); 166 } else { 167 $('#header #headerBottom').removeClass('fixedstyle'); 168 } 169 }); 170 $(window).ready(function(){ 171 if( $(window).scrollTop() > fix + $(window).height() -65 ) { 172 $('#header #headerBottom').addClass('fixedstyle'); 173 } else { 174 $('#header #headerBottom').removeClass('fixedstyle'); 175 } 176 }); 177 }); 178 179//window popup script 180function winPop(url) { 181 window.open(url, "popup", "width=300,height=300,left=10,top=10,resizable=no,scrollbars=no"); 182} 183/** 184 * document.location.href split 185 * return array Param 186 */ 187function getQueryString(sKey) 188{ 189 var sQueryString = document.location.search.substring(1); 190 var aParam = {}; 191 192 if (sQueryString) { 193 var aFields = sQueryString.split("&"); 194 var aField = []; 195 for (var i=0; i<aFields.length; i++) { 196 aField = aFields[i].split('='); 197 aParam[aField[0]] = aField[1]; 198 } 199 } 200 201 aParam.page = aParam.page ? aParam.page : 1; 202 return sKey ? aParam[sKey] : aParam; 203}; 204 205$(document).ready(function(){ 206 // tab 207 $.eTab = function(ul){ 208 $(ul).find('a').click(function(){ 209 var _li = $(this).parent('li').addClass('selected').siblings().removeClass('selected'), 210 _target = $(this).attr('href'), 211 _siblings = '.' + $(_target).attr('class'); 212 $(_target).show().siblings(_siblings).hide(); 213 return false 214 }); 215 } 216 if ( window.call_eTab ) { 217 call_eTab(); 218 }; 219}); 220(function($){ 221$.fn.extend({ 222 center: function() { 223 this.each(function() { 224 var 225 $this = $(this), 226 $w = $(window); 227 $this.css({ 228 position: "absolute", 229 top: ~~(($w.height() - $this.outerHeight()) / 2) + $w.scrollTop() + "px", 230 left: ~~(($w.width() - $this.outerWidth()) / 2) + $w.scrollLeft() + "px" 231 }); 232 }); 233 return this; 234 } 235}); 236$(function() { 237 var $container = function(){/* 238<div id="modalContainer"> 239 <iframe id="modalContent" scroll="0" scrolling="no" frameBorder="0"></iframe> 240</div>'); 241*/}.toString().slice(14,-3); 242 $('body') 243 .append($('<div id="modalBackpanel"></div>')) 244 .append($($container)); 245 function closeModal () { 246 $('#modalContainer').hide(); 247 $('#modalBackpanel').hide(); 248 } 249 $('#modalBackpanel').click(closeModal); 250 zoom = function ($piProductNo, $piCategoryNo, $piDisplayGroup) { 251 var $url = '/product/image_zoom.html?product_no=' + $piProductNo + '&cate_no=' + $piCategoryNo + '&display_group=' + $piDisplayGroup; 252 $('#modalContent').attr('src', $url); 253 $('#modalContent').bind("load",function(){ 254 $(".header .close",this.contentWindow.document.body).bind("click", closeModal); 255 }); 256 $('#modalBackpanel').css({width:$("body").width(),height:$("body").height(),opacity:.4}).show(); 257 $('#modalContainer').center().show(); 258 } 259}); 260})(jQuery); 261$(document).ready(function(){ 262 if (typeof(EC_SHOP_MULTISHOP_SHIPPING) != "undefined") { 263 var sShippingCountryCode4Cookie = 'shippingCountryCode'; 264 var bShippingCountryProc = false;
265 266 // ë°°ì¡êµê° ì í ì¤ì ì´ ì¬ì©ìí¨ì´ë©´ ì¨ê¹ 267 if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingCountrySelection === false) { 268 $('.xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist').hide(); 269 $('.xans-layout-multishoplist .xans-layout-multishoplistmultioption .xans-layout-multishoplistmultioptioncountry').hide(); 270 } else { 271 $('.thumb .xans-layout-multishoplistitem').hide(); 272 var aShippingCountryCode = document.cookie.match('(^|;) ?'+sShippingCountryCode4Cookie+'=([^;]*)(;|$)'); 273 if (typeof(aShippingCountryCode) != 'undefined' && aShippingCountryCode != null && aShippingCountryCode.length > 2) { 274 var sShippingCountryValue = aShippingCountryCode[2]; 275 } 276 277 // query stringì¼ë¡ ëì´ ì¨ ë°°ì¡êµê° ê°ì´ ìë¤ë©´, ê·¸ ê°ì ì ì©í¨ 278 var aHrefCountryValue = decodeURIComponent(location.href).split("/?country="); 279 280 if (aHrefCountryValue.length == 2) { 281 var sShippingCountryValue = aHrefCountryValue[1]; 282 } 283 284 // ë©ì¸ íì´ì§ìì êµê°ì íì ìí ê²½ì°, ê·¸ ì¸ì íì´ì§ìì ì í ë ê°ì´ ì ëì¤ë íì ì²ë¦¬ 285 if (location.href.split("/").length != 4 && $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val()) { 286 $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a .ship span").text(" : "+$(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist option:selected").text().split("SHIPPING TO : ").join("")); 287 288 if ($("#f_country").length > 0 && location.href.indexOf("orderform.html") > -1) { 289 $("#f_country").val($(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val()); 290 } 291 } 292 if (typeof(sShippingCountryValue) != "undefined" && sShippingCountryValue != "" && sShippingCountryValue != null) { 293 sShippingCountryValue = sShippingCountryValue.split("#")[0]; 294 var bShippingCountryProc = true; 295 296 $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val(sShippingCountryValue); 297 $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a .ship span").text(" : "+$(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist option:selected").text().split("SHIPPING TO : ").join("")); 298 var expires = new Date(); 299 expires.setTime(expires.getTime() + (30 * 24 * 60 * 60 * 1000)); // 30ì¼ê° ì¿ í¤ ì ì§ 300 document.cookie = sShippingCountryCode4Cookie+'=' + $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val() +';path=/'+ ';expires=' + expires.toUTCString(); 301 if ($("#f_country").length > 0 && location.href.indexOf("orderform.html") > -1) { 302 $("#f_country").val(sShippingCountryValue).change();; 303 } 304 } 305 } 306 // ì¸ì´ì í ì¤ì ì´ ì¬ì©ìí¨ì´ë©´ ì¨ê¹ 307 if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingLanguageSelection === false) { 308 $('.xans-layout-multishopshipping .xans-layout-multishopshippinglanguagelist').hide(); 309 $('.xans-layout-multishoplist .xans-layout-multishoplistmultioption .xans-layout-multishoplistmultioptionlanguage').hide(); 310 } else { 311 $('.thumb .xans-layout-multishoplistitem').hide(); 312 } 313 314 // ë°°ì¡êµê° ë° ì¸ì´ ì¤ì ì´ ë ë¤ ì¬ì©ìí¨ì´ë©´ ì¨ê¹ 315 if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShipping === false) { 316 $(".xans-layout-multishopshipping").hide(); 317 $('.xans-layout-multishoplist .xans-layout-multishoplistmultioption').hide(); 318 } else if (bShippingCountryProc === false && location.href.split("/").length == 4) { // ë°°ì¡êµê° ê°ì ì²ë¦¬í ì ì´ ìê³ , ë©ì¸íë©´ì¼ ëë§ ì í ë ì´ì´ë¥¼ ëì 319 var sShippingCountryValue = $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val(); 320 $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val(sShippingCountryValue); 321 $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a .ship span").text(" : "+$(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist option:selected").text().split("SHIPPING TO : ").join("")); 322 // ë°°ì¡êµê° ì íì ì¬ì©í´ì¼ ë ì´ì´ë¥¼ ë³´ì´ê² í¨ 323 if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingCountrySelection === true) { 324 $(".xans-layout-multishopshipping").show(); 325 } 326 } 327 328 $(".xans-layout-multishopshipping .close").bind("click", function() { 329 $(".xans-layout-multishopshipping").hide(); 330 }); 331 332 $(".xans-layout-multishopshipping .ec-base-button a").bind("click", function() { 333 var expires = new Date(); 334 expires.setTime(expires.getTime() + (30 * 24 * 60 * 60 * 1000)); // 30ì¼ê° ì¿ í¤ ì ì§ 335 document.cookie = sShippingCountryCode4Cookie+'=' + $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val() +';path=/'+ ';expires=' + expires.toUTCString(); 336 337 // ëë©ì¸ 문ì ë¡ ì¿ í¤ë¡ ë°°ì¡êµê° ì¤ì ì´ ì ëë ê²½ì°ë¥¼ ìí´ query stringì¼ë¡ ë°°ì¡êµê° ê°
337ì ëê¹ 338 var sQuerySting = (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingCountrySelection === false) ? "" : "/?country="+encodeURIComponent($(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val()); 339 340 location.href = '//'+$(".xans-layout-multishopshipping .xans-layout-multishopshippinglanguagelist").val()+sQuerySting; 341 }); 342 $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a").bind("click", function() { 343 $(".xans-layout-multishopshipping").show(); 344 }); 345 } 346});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.