PageSourceSearch

https://top.ge/source/js/custom.js

js top.ge collected 2026-10-03 22:23:23 UTC 4,930 bytes, 148 lines download raw bytes

1$(document).ready(function() {
2	$(document).on('change', '.category_select', function(event) {
3		event.preventDefault();
4		window.location.href = $('select[name=category_select]').val();
5	});
6	$(document).on('click', '.cover_mn_bg', function(event) {
7		event.preventDefault();
8		document.getElementById("mySidenav").style.width = "0";
9		$('body').removeClass('cover_shown');
10    	$('.cover_mn_bg').hide();
11	});
12});
13/* Set the width of the side navigation to 250px */
14function openNav() {
15    document.getElementById("mySidenav").style.width = "300px";
16    $('.cover_mn_bg').show('fast');
17    $('body').addClass('cover_shown');
18}
19
20/* Set the width of the side navigation to 0 */
21function closeNav() {
22    document.getElementById("mySidenav").style.width = "0";
23    $('body').removeClass('cover_shown');
24    $('.cover_mn_bg').hide();
25}
26$( function() {
27    $("a[title]").tooltip();
28    $("span[title]").tooltip();
29  } );
30$(document).ready(function() {
31	$(document).on('click', '.search-button', function(event) {
32		event.preventDefault();
33		$(this).addClass('opened');
34		setTimeout(function(){
35		    $(".search_input").focus();
36		},  200);
37		$('#search_holder').addClass('opened');
38	});
39});
40$(document).ready(function() {
41	$(document).on('keyup', '.search_input', function(event) {
42		event.preventDefault();
43		sr_val = $(this).val();
44		if (sr_val.length > 0) {
45			$('.clear-search').css('display', 'block');
46		} else {
47			$('.clear-search').css('display', 'none');
48		}
49		/* Act on the event */
50	});
51	
52});
53$(document).ready(function() {
54	$(document).on('click', '.clear-search', function(event) {
55		event.preventDefault();
56		$('.search_input').val('');
57		setTimeout(function(){
58		    $(".search_input").focus();
59		},  100);
60		/* Act on the event */
61	});
62});
63$(document).ready(function() {
64	$(document).on('click', '.close-search', function(event) {
65		event.preventDefault();
66		$('.search-button').removeClass('opened');
67		$('#search_holder').removeClass('opened');
68	});
69});
70$(document).on('click', ".wtf_s_mn" , function(event) {
71	event.preventDefault();
72  $( ".to_shw_mn" ).slideToggle(200, function() {
73  	if ($( ".wtf_s_mn" ).hasClass('active_open')) {$( ".wtf_s_mn" ).removeClass('active_open');} else {$( ".wtf_s_mn" ).addClass('active_open');}
74  	if ($( ".hdr_main" ).hasClass('active_open')) {$( ".hdr_main" ).removeClass('active_open');} else {$( ".hdr_main" ).addClass('active_open');}
75    
76  });
77});
78
79$(document).ready(function() {
80	$(document).on('click', '.close_info', function(event) {
81		event.preventDefault();
82        $('.ui-accordion-content').slideUp('500');
83        $('.ui-accordion-content').removeClass('ui-accordion-content-active');
84        $('.ui-accordion-header').removeClass('ui-state-active');
85        $('.ui-accordion-header').removeClass('ui-accordion-header-active');
86        $('.ui-accordion-header').addClass('ui-accordion-header-collapsed');
87        $('.ui-accordion-header').addClass('ui-corner-all');
88    });
89});
90
91$(document).ready(function() {
92	$(document).on('click', '.accept_coockie', function(event) {
93		event.preventDefault();
94		/* Act on the event */
95		setCookie('accepted_C',1,365);
96		$('.coockie_policy').hide('fast');
97	});
98});
99
100function setCookie(cname, cvalue, exdays) {
101    var d = new Date();
102    d.setTime(d.getTime() + (exdays * 24 * 60 * 60 * 1000));
103    var expires = "expires="+d.toUTCString();
104    document.cookie = cname + "=" + cvalue + ";" + expires + ";path=/";
105}
106
107function getCookie(cname) {
108    var name = cname + "=";
109    var ca = document.cookie.split(';');
110    for(var i = 0; i < ca.length; i++) {
111        var c = ca[i];
112        while (c.charAt(0) == ' ') {
113            c = c.substring(1);
114        }
115        if (c.indexOf(name) == 0) {
116            return c.substring(name.length, c.length);
117        }
118    }
119    return "";
120}
121$(document).ready(function() {
122	$(document).on('click', '.to_mdl_s', function(event) {
123		event.preventDefault();
124		$('.modal-body').html('იტვირთება... <img src="/source/img/loader_a.gif">');
125		$('.class_a').css('display', 'block');
126		var title_s = $(this).attr('data-ttitle');
127		var site_id = $(this).attr('data-s_id');
128		$('.modal-title').html(title_s);
129		$('#op_modal').modal('show');
130		$.get('/where_morea/'+site_id, function(data) {
131			$('.modal-body').html(data);
132		});
133	});
134});
135$(document).ready(function() {
136	$(document).on('click', '.to_mdl_s2', function(event) {
137		event.preventDefault();
138		$('.class_a').css('display', 'none');
139		$('.modal-body').html('იტვირთება... <img src="/source/img/loader_a.gif">');
140		var title_s = $(this).attr('data-ttitle');
141		var site_id = $(this).attr('data-s_id');
142		$('.modal-title').html(title_s);
143		$('#op_modal').modal('show');
144		$.get('/whois/'+site_id, function(data) {
145			$('.modal-body').html(data);
146		});
147	});
148});

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.