PageSourceSearch

https://gwgs.go.kr/js/tour/2023/acego.layout.js

js gwgs.go.kr collected 2026-10-02 17:49:00 UTC 7,158 bytes, 209 lines download raw bytes

1$(document).ready(function () {
2
3        // // 상단팝업
4        $(function(){
5            var opnum = $('#op_layout .op-wrap').children('.thm-box').length
6            console.log(opnum)
7            if (opnum < 1) {
8                $('#op_layout').removeClass('open')
9                $('#op_layout').addClass('op-close')
10                $('#top_layout .top_wrap .utile_wrap li.pop-alaram').hide()
11            } else {
12                $('#op_layout').addClass('open')
13                $('#op_layout').removeClass('op-close')
14                $('#top_layout .top_wrap .utile_wrap li.pop-alaram').show()
15            }
16        })
17    
18        var enableCookies = true;
19        var opPOPUP = getCookie('opPOPUP');
20        // console.log(opPOPUP)
21        if (enableCookies && startCookies('opPOPUP') == '') {
22            $(window).load(function () {
23                $('#op_layout').show()
24            });
25        }
26        // $("#op_layout .op-wrap .btn-wrap .op-close-btn").on("click", function () {
27        //     if ($("#today").prop("checked")) {
28        //         createCookie('opPOPUP', true, 1);
29        //     }
30        //     $('#op_layout').hide();
31        // });
32    
33        $('#op_layout .op-wrap .btn-wrap .op-close-btn').click(function (event) {
34    
35            if ($("input:checkbox[id=today]").is(":checked") == true) {
36                createCookie('opPOPUP', "done", 1);
37            }
38    
39            $('#op_layout').hide()
40    
41            event.preventDefault();
42        })
43    
44        if (!opPOPUP) {
45            $('#op_layout').show()
46            $('#op_layout').addClass('open')
47        } else {
48            $('#op_layout').hide()
49            $('#op_layout').removeClass('open')
50        }
51    
52        function createCookie(name, value, days) {
53            var expires;
54            if (days) {
55                var date = new Date();
56                date.setTime(date.getTime() + (days * 24 * 60 * 60 * 1000));
57                expires = "; expires=" + date.toGMTString();
58            }
59            else {
60                expires = "";
61            }
62            document.cookie = name + "=" + value + expires + "; path=/";
63        }
64        function startCookies(c_name) {
65            if (document.cookie.length > 0) {
66                c_start = document.cookie.indexOf(c_name + "=");
67                if (c_start != -1) {
68                    c_start = c_start + c_name.length + 1;
69                    c_end = document.cookie.indexOf(";", c_start);
70                    if (c_end == -1) {
71                        c_end = document.cookie.length;
72                    }
73                    return unescape(document.cookie.substring(c_start, c_end));
74                }
75            }
76            return "";
77        }
78    
79        $(function() {
80            $('#op_layout .op-wrap .btn-wrap .op-close-btn').click(function(){
81                $('#op_layout').hide()
82            });
83            $('#top_layout .top_wrap .utile_wrap li.pop-alaram .btn-pa').click(function(){
84                $('#op_layout').show()
85            });
86        });
87    
88    
89    
90
91    $(".tmtbui-01 .toTop a").click(function (e) {
92        e.preventDefault()
93        $("html, body").animate({ "scrollTop": 0 }, 500);
94
95    });
96
97    
98    $('.display-option .btn-do').on('focus mouseenter', function(){
99        $(this).parent().addClass('ov')
100    });
101    $('.display-option .btn-do').on('focusout mouseleave', function(){
102        $(this).parent().removeClass('ov')
103    });
104
105
106    
107    // 언어선택
108    $(".language-link").each(function () {
109        var $selWrap = $(this),
110            $curBtn = $selWrap.find(">button");
111
112        $curBtn.on("click", function (e) {
113            var $thisBtn = $(this),
114                $selList = $thisBtn.siblings(".lan-wrap");
115
116            if ($selWrap.hasClass("on")) {
117                $selWrap.removeClass("on");
118                $(this).find('span i').text('닫힘버튼');
119
120            } else {
121                $selWrap.addClass("on");
122                $(this).find('span i').text('열림버튼');
123            }
124
125            $('body').on("click", function (e) {
126                if (!$selWrap.has(e.target).length) {
127                    $selWrap.removeClass('on');
128                    $(this).find('span i').text('닫힘버튼');
129                }
130            });
131
132            $selWrap.find("a, button").filter(":first").on("keydown", function (e) {
133                if (e.shiftKey && e.keyCode === 9) {
134                    $selWrap.removeClass('on');
135                    $(this).find('span i').text('닫힘버튼');
136                }
137            });
138            $selWrap.find("a, button").filter(":last").on("keydown", function (e) {
139                if (!e.shiftKey && e.keyCode === 9) {
140                    $selWrap.removeClass('on');
141                    $(this).find('span i').text('닫힘버튼');
142                }
143            });
144
145            e.preventDefault();
146        });
147    });
148
149    $(".favorite_site_open").on("click", function () {
150        $(".favorite_site_cnt").addClass("open");
151    });
152
153    $(".favorite_site_close").on("click", function () {
154        $(".favorite_site_cnt").removeClass("open");
155    });
156
157    // 모바일 메뉴
158    $(function(){
159        $('#mobile-menu .modal-dialog .modal-content .modal-body .depth2_ul li .depth3_ul').prev().addClass('dep')
160    })
161
162    $(function() {
163        $('.modal-header .topUtile .utile_wrap li.lan> a').click(function(){
164            $(this).toggleClass('active');
165            if ($(this).hasClass('active')){
166                $('.modal-header .topUtile .utile_wrap li.lan ul').css({'display':'block'});
167            }else{
168                $('.modal-header .topUtile .utile_wrap li.lan ul').css({'display':'none'});
169            }
170        });
171    });
172
173    $('[data-type=tab]').each(function (key, item) {
174        var _$tabmenu;
175        var tabIdName = 'tab' + key;
176        this.id = tabIdName;
177        var tabId = '#' + tabIdName;
178        var n = 0;
179
180        var $tab = $(tabId).find('> .board-item');
181        var $title = $(tabId).find('> .board-item > .board-title');
182
183        $title.next('.board-content').hide();
184        $title.next('.board-more').hide();
185        $tab.eq(n).addClass('active');
186        $tab.eq(n).children('.board-title').next('.board-content').show();
187        $tab.eq(n).children('.board-title').next('.board-more').show();
188
189        $title.on("click", function () {
190            var url;
191            if ($(this).attr("href")) url = $(this).attr('href').attr('target', $(this).attr('target'));
192            $title.next('.board-content').hide();
193            $title.next('.board-more').hide();
194            $title.parent().removeClass('active');
195            $(this).next('.board-content').show();
196            $(this).next('.board-more').show();
197            $(this).parent().addClass('active');
198            //$("[data-slider]").slick("setPosition"); slick 슬라이드 사용시 주석 풀어야 합니다.
199            return false;
200        });
201    });
202
203
204
205
206
207
208
209})

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.