PageSourceSearch

https://sunnyst.com/ind-script/optimizer_user.php?filename=jY1RDsI…a58dd9a82dacda932f48b19&t=1554364588&user=T

js sunnyst.com collected 2026-10-06 14:04:08 UTC 15,340 bytes, 356 lines download raw bytes

1$(function(){ 
2    if($(".menuCategory > li").length==0){
3         $(".menuCategory").hide();
4    };
5});
6/**
7 * 움직이는 배너 Jquery Plug-in
8 * @author  cafe24
9 */
10
11(function($){
12
13    $.fn.floatBanner = function(options) {
14        options = $.extend({}, $.fn.floatBanner.defaults , options);
15
16        return this.each(function() {
17            var aPosition = $(this).position();
18            var jbOffset = $(this).offset();
19            var node = this;
20
21            $(window).scroll(function() {
22                var _top = $(document).scrollTop();
23                _top = (aPosition.top < _top) ? _top : aPosition.top;
24
25                setTimeout(function () {
26                    var newinit = $(document).scrollTop();
27
28                    if ( newinit > jbOffset.top ) {
29                        _top -= jbOffset.top;
30                        var container_height = $("#wrap").height();
31                        var quick_height = $(node).height();
32                        var cul = container_height - quick_height;
33                        if(_top > cul){
34                            _top = cul;
35                        }
36                    }else {
37                        _top = 0;
38                    }
39
40                    $(node).stop().animate({top: _top}, options.animate);
41                }, options.delay);
42            });
43        });
44    };
45
46    $.fn.floatBanner.defaults = {
47        'animate'  : 500,
48        'delay'    : 500
49    };
50
51})(jQuery);
52
53/**
54 * 문서 구동후 시작
55 */
56$(document).ready(function(){
57    $('#banner:visible, #quick:visible').floatBanner();
58
59    //placeholder
60    $(".ePlaceholder input, .ePlaceholder textarea").each(function(i){
61        var placeholderName = $(this).parents().attr('title');
62        $(this).attr("placeholder", placeholderName);
63    });
64    /* placeholder ie8, ie9 */
65    $.fn.extend({
66        placeholder : function() {
67            //IE 8 버전에는 hasPlaceholderSupport() 값이 false를 리턴
68           if (hasPlaceholderSupport() === true) {
69                return this;
70            }
71            //hasPlaceholderSupport() 값이 false 일 경우 아래 코드를 실행
72            return this.each(function(){
73                var findThis = $(this);
74                var sPlaceholder = findThis.attr('placeholder');
75                if ( ! sPlaceholder) {
76                   return;
77                }
78                findThis.wrap('<label class="ePlaceholder" />');
79                var sDisplayPlaceHolder = $(this).val() ? ' style="display:none;"' : '';
80                findThis.before('<span' + sDisplayPlaceHolder + '>' + sPlaceholder + '</span>');
81                this.onpropertychange = function(e){
82                    e = event || e;
83                    if (e.propertyName == 'value') {
84                        $(this).trigger('focusout');
85                    }
86                };
87                //공통 class
88                var agent = navigator.userAgent.toLowerCase();
89                if (agent.indexOf("msie") != -1) {
90                    $(".ePlaceholder").css({"position":"relative"});
91                    $(".ePlaceholder span").css({"position":"absolute", "padding":"0 4px", "color":"#878787"});
92                    $(".ePlaceholder label").css({"padding":"0"});
93                }
94            });
95        }
96    });
97
98    $(':input[placeholder]').placeholder(); //placeholder() 함수를 호출
99
100    //클릭하면 placeholder 숨김
101    $('body').delegate('.ePlaceholder span', 'click', function(){
102        $(this).hide();
103    });
104
105    //input창 포커스 인 일때 placeholder 숨김
106    $('body').delegate('.ePlaceholder :input', 'focusin', function(){
107        $(this).prev('span').hide();
108    });
109
110    //input창 포커스 아웃 일때 value 가 true 이면 숨김, false 이면 보여짐
111    $('body').delegate('.ePlaceholder :input', 'focusout', function(){
112        if (this.value) {
113            $(this).prev('span').hide();
114        } else {
115            $(this).prev('span').show();
116        }
117    });
118
119    //input에 placeholder가 지원이 되면 true를 안되면 false를 리턴값으로 던져줌
120    function hasPlaceholderSupport() {
121        if ('placeholder' in document.createElement('input')) {
122            return true;
123        } else {
124            return false;
125        }
126    }
127});
128
129/**
130 *  썸네일 이미지 엑박일경우 기본값 설정
131 */
132$(window).load(function() {
133    $("img.thumb,img.ThumbImage,img.BigImage").each(function($i,$item){
134        var $img = new Image();
135        $img.onerror = function () {
136                $item.src="//img.echosting.cafe24.com/thumb/img_product_big.gif";
137        }
138        $img.src = this.src;
139    });
140});
141
142/**
143 *  tooltip
144 */
145$('.eTooltip').each(function(i){
146    $(this).find('.btnClose').attr('tabIndex','-1');
147});
148//tooltip input focus
149$('.eTooltip').find('input').focus(function() {
150    var targetName = returnTagetName(this);
151    targetName.siblings('.ec-base-tooltip').show();
152});
153$('.eTooltip').find('input').focusout(function() {
154    var targetName = returnTagetName(this);
155    targetName.siblings('.ec-base-tooltip').hide();
156});
157function returnTagetName(_this){
158    var ePlacename = $(_this).parent().attr("class");
159    var targetName;
160    if(ePlacename == "ePlaceholder"){ //ePlaceholder 대응
161        targetName = $(_this).parents();
162    }else{
163        targetName = $(_this);
164    }
165    return targetName;
166}
167
168/**
169 *  eTab
170 */
171 $("body").delegate(".eTab a", "click", function(e){
172    // 클릭한 li 에 selected 클래스 추가, 기존 li에 있는 selected 클래스는 삭제.
173    var _li = $(this).parent("li").addClass("selected").siblings().removeClass("selected"),
174    _target = $(this).attr("href"),
175    _siblings = $(_target).attr("class"),
176    _arr = _siblings.split(" "),
177    _classSiblings = "."+_arr[0];
178
179    //클릭한 탭에 해당하는 요소는 활성화, 기존 요소는 비활성화 함.
180    $(_target).show().siblings(_classSiblings).hide();
181
182
183    //preventDefault 는 a 태그 처럼 클릭 이벤트 외에 별도의 브라우저 행동을 막기 위해 사용됨.
184    e.preventDefault();
185});
186
187
188
189//window popup script
190function winPop(url) {
191    window.open(url, "popup", "width=300,height=300,left=10,top=10,resizable=no,scrollbars=no");
192}
193/**
194 * document.location.href split
195 * return array Param
196 */
197function getQueryString(sKey)
198{
199    var sQueryString = document.location.search.substring(1);
200    var aParam       = {};
201
202    if (sQueryString) {
203        var aFields = sQueryString.split("&");
204        var aField  = [];
205        for (var i=0; i<aFields.length; i++) {
206            aField = aFields[i].split('=');
207            aParam[aField[0]] = aField[1];
208        }
209    }
210
211    aParam.page = aParam.page ? aParam.page : 1;
212    return sKey ? aParam[sKey] : aParam;
213};
214
215$(document).ready(function(){
216    // tab
217    $.eTab = function(ul){
218        $(ul).find('a').click(function(){
219            var _li = $(this).parent('li').addClass('selected').siblings().removeClass('selected'),
220                _target = $(this).attr('href'),
221                _siblings = '.' + $(_target).attr('class');
222            $(_target).show().siblings(_siblings).hide();
223            return false
224        });
225    }
226    if ( window.call_eTab ) {
227        call_eTab();
228    };
229});
230(function($){
231$.fn.extend({
232    center: function() {
233        this.each(function() {
234            var
235                $this = $(this),
236                $w = $(window);
237            $this.css({
238                position: "absolute",
239                top: ~~(($w.height() - $this.outerHeight()) / 2) + $w.scrollTop() + "px",
240                left: ~~(($w.width() - $this.outerWidth()) / 2) + $w.scrollLeft() + "px"
241            });
242        });
243        return this;
244    }
245});
246$(function() {
247    var $container = function(){/*
248<div id="modalContainer">
249    <iframe id="modalContent" scroll="0" scrolling="no" frameBorder="0"></iframe>
250</div>');
251*/}.toString().slice(14,-3);
252    $('body')
253    .append($('<div id="modalBackpanel"></div>'))
254    .append($($container));
255    function closeModal () {
256        $('#modalContainer').hide();
257        $('#modalBackpanel').hide();
258    }
259    $('#modalBackpanel').click(closeModal);
260    zoom = function ($piProductNo, $piCategoryNo, $piDisplayGroup) {
261        var $url = '/product/image_zoom.html?product_no=' + $piProductNo + '&cate_no=' + $piCategoryNo + '&display_group=' + $piDisplayGroup;
262        $('#modalContent').attr('src', $url);
263        $('#modalContent').bind("load",function(){
264            $(".header .close",this.contentWindow.document.body).bind("click", closeModal);
265        });
266        $('#modalBackpanel').css({width:$("body").width(),height:$("body").height(),opacity:.4}).show();
267        $('#modalContainer').center().show();
268    }
269});
270})(jQuery);
271$(document).ready(function(){
272    if (typeof(EC_SHOP_MULTISHOP_SHIPPING) != "undefined") {
273        var sShippingCountryCode4Cookie = 'shippingCountryCode';
274        var bShippingCountryProc = false;
275
276        // 배송국가 선택 설정이 사용안함이면 숨김
277        if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingCountrySelection === false) {
278            $('.xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist').hide();
279            $('.xans-layout-multishoplist .xans-layout-multishoplistmultioption .xans-layout-multishoplistmultioptioncountry').hide();
280        } else {
281            $('.thumb .xans-layout-multishoplistitem').hide();
282            var aShippingCountryCode = document.cookie.match('(^|;) ?'+sShippingCountryCode4Cookie+'=([^;]*)(;|$)');
283            if (typeof(aShippingCountryCode) != 'undefined' && aS
283hippingCountryCode != null && aShippingCountryCode.length > 2) {
284                var sShippingCountryValue = aShippingCountryCode[2];
285            }
286
287            // query string으로 넘어 온 배송국가 값이 있다면, 그 값을 적용함
288            var aHrefCountryValue = decodeURIComponent(location.href).split("/?country=");
289
290            if (aHrefCountryValue.length == 2) {
291                var sShippingCountryValue = aHrefCountryValue[1];
292            }
293
294            // 메인 페이지에서 국가선택을 안한 경우, 그 외의 페이지에서 셋팅된 값이 안 나오는 현상 처리
295            if (location.href.split("/").length != 4 && $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val()) {
296                $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a .ship span").text(" : "+$(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist option:selected").text().split("SHIPPING TO : ").join(""));
297
298                if ($("#f_country").length > 0 && location.href.indexOf("orderform.html") > -1) {
299                    $("#f_country").val($(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val());
300                }
301            }
302            if (typeof(sShippingCountryValue) != "undefined" && sShippingCountryValue != "" && sShippingCountryValue != null) {
303                sShippingCountryValue = sShippingCountryValue.split("#")[0];
304                var bShippingCountryProc = true;
305
306                $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val(sShippingCountryValue);
307                $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a .ship span").text(" : "+$(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist option:selected").text().split("SHIPPING TO : ").join(""));
308                var expires = new Date();
309                expires.setTime(expires.getTime() + (30 * 24 * 60 * 60 * 1000)); // 30일간 쿠키 유지
310                document.cookie = sShippingCountryCode4Cookie+'=' + $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val() +';path=/'+ ';expires=' + expires.toUTCString();
311                if ($("#f_country").length > 0 && location.href.indexOf("orderform.html") > -1) {
312                    $("#f_country").val(sShippingCountryValue).change();;
313                }
314            }
315        }
316        // 언어선택 설정이 사용안함이면 숨김
317        if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingLanguageSelection === false) {
318            $('.xans-layout-multishopshipping .xans-layout-multishopshippinglanguagelist').hide();
319            $('.xans-layout-multishoplist .xans-layout-multishoplistmultioption .xans-layout-multishoplistmultioptionlanguage').hide();
320        } else {
321            $('.thumb .xans-layout-multishoplistitem').hide();
322        }
323
324        // 배송국가 및 언어 설정이 둘 다 사용안함이면 숨김
325        if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShipping === false) {
326            $(".xans-layout-multishopshipping").hide();
327            $('.xans-layout-multishoplist .xans-layout-multishoplistmultioption').hide();
328        } else if (bShippingCountryProc === false && location.href.split("/").length == 4) { // 배송국가 값을 처리한 적이 없고, 메인화면일 때만 선택 레이어를 띄움
329            var sShippingCountryValue = $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val();
330            $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val(sShippingCountryValue);
331            $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a .ship span").text(" : "+$(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist option:selected").text().split("SHIPPING TO : ").join(""));
332            // 배송국가 선택을 사용해야 레이어를 보이게 함
333            if (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingCountrySelection === true) {
334                $(".xans-layout-multishopshipping").show();
335            }
336        }
337
338        $(".xans-layout-multishopshipping .close").bind("click", function() {
339            $(".xans-layout-multishopshipping").hide();
340        });
341
342        $(".xans-layout-multishopshipping .ec-base-button a").bind("click", function() {
343            var expires = new Date();
344            expires.setTime(expires.getTime() + (30 * 24 * 60 * 60 * 1000)); // 30일간 쿠키 유지
345            document.cookie = sShippingCountryCode4Cookie+'=' + $(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val() +';path=/'+ ';expires=' + expires.toUTCString();
346
347            // 도메인 문제로 쿠키로 배송국가 설정이 안 되는 경우를 위해 query string으로 배송국가 값
347을 넘김
348            var sQuerySting = (EC_SHOP_MULTISHOP_SHIPPING.bMultishopShippingCountrySelection === false) ? "" : "/?country="+encodeURIComponent($(".xans-layout-multishopshipping .xans-layout-multishopshippingcountrylist").val());
349
350            location.href = '//'+$(".xans-layout-multishopshipping .xans-layout-multishopshippinglanguagelist").val()+sQuerySting;
351        });
352        $(".xans-layout-multishoplist .xans-layout-multishoplistmultioption a").bind("click", function() {
353            $(".xans-layout-multishopshipping").show();
354        });
355    }
356});

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.