PageSourceSearch

https://business-up.org/wp-content/plugins/belingogeo/js/belingoGeo.js?ver=1.13.2

js business-up.org collected 2026-10-07 00:06:45 UTC 3,291 bytes, 98 lines download raw bytes

1function show_popup_window(window_id) {
2	var window_width = jQuery(window).width();
3	var margin_top = parseInt(jQuery(window_id).height())/2;
4	var margin_left = parseInt(jQuery(window_id).width())/2;
5	jQuery(window_id).css('margin-top', -margin_top);
6	if(window_width >= 787) {
7		jQuery(window_id).css('margin-left', -margin_left);
8	}else{
9		jQuery(window_id).css('left', 'auto');
10	}
11	jQuery(window_id).show();
12	jQuery('.popup-window-overlay').show();
13}
14
15function belingogeo_preloader_city_list() {
16	jQuery('.quick-locations__values__container').html('<div style="padding:30px 0;text-align:center;"><svg xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.0" width="100px" height="100px" viewBox="0 0 128 128" xml:space="preserve"><path fill="#a0a1a7" d="M64.4 16a49 49 0 0 0-50 48 51 51 0 0 0 50 52.2 53 53 0 0 0 54-52c-.7-48-45-55.7-45-55.7s45.3 3.8 49 55.6c.8 32-24.8 59.5-58 60.2-33 .8-61.4-25.7-62-60C1.3 29.8 28.8.6 64.3 0c0 0 8.5 0 8.7 8.4 0 8-8.6 7.6-8.6 7.6z"><animateTransform attributeName="transform" type="rotate" from="0 64 64" to="360 64 64" dur="1800ms" repeatCount="indefinite"></animateTransform></path></svg></div>');
17}
18
19jQuery(document).ready(function() {
20
21	var data = { 
22		action: 'get_widget_city'
23	}
24	jQuery.post(belingoGeo.ajaxurl, data, function(response) {
25		jQuery('.geolocation__value').html(response);
26	});
27
28	var data = { 
29		action: 'show_city_question',
30		back_url: belingoGeo.backurl,
31		object_id: belingoGeo.object_id,
32		object: belingoGeo.object,
33	}
34	jQuery.post(belingoGeo.ajaxurl, data, function(response) {
35
36		if(response.redirect) {
37			location.href = response.redirect;
38		}else{
39			jQuery('.geolocation_with_question__link').after(response.show_question);
40		}
41
42	});
43
44	jQuery(document).on('click','.select_geo_city', function(e) {
45
46		e.preventDefault();
47
48		city_name = jQuery(this).data('name');
49		city_name_orig = jQuery(this).data('name-orig');
50
51		var data = { 
52			action: 'write_city_cookie',
53			city_name: city_name,
54			city_name_orig: city_name_orig,
55			object_id: belingoGeo.object_id,
56			object: belingoGeo.object,
57			back_url: belingoGeo.backurl
58		}
59		jQuery.post(belingoGeo.ajaxurl, data, function(response) {
60			location.href = response.redirect;
61		});
62	});
63
64	jQuery(document).on('click','.continue-without-geo', function(e) {
65		e.preventDefault();
66		var data = { 
67			action: 'write_nogeo_cookie',
68			back_url: belingoGeo.backurl
69		}
70		jQuery.post(belingoGeo.ajaxurl, data, function(response) {
71			location.href = response.redirect;
72		});
73	});
74
75	jQuery(document).on('click','#geolocationChangeCity, .geolocationChangeCity, .geolocation__link', function() {
76		show_popup_window('#cityChange');
77		var data = {
78			action: 'load_cities'
79		}
80		jQuery.ajax({
81		  type: 'POST',
82		  url: belingoGeo.ajaxurl,
83		  data: data,
84		  beforeSend: function() {
85		  	belingogeo_preloader_city_list();
86		  },
87		  success: function(response) {
88		  	jQuery('.quick-locations__values__container').html(response);
89		  }
90		});
91	});
92
93	jQuery(document).on('click','.popup-window-close-icon', function() {
94    	jQuery('.popup-window').hide();
95    	jQuery('.popup-window-overlay').hide();
96	});
97
98});

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.