PageSourceSearch

https://www.buscroatia.com/js/main_postwp.js?ver=1.00

js buscroatia.com collected 2026-10-02 18:58:27 UTC 4,516 bytes, 178 lines download raw bytes

1
2
3
4
5/*****************
6 * Page is Ready
7 *****************/
8$(document).ready(function(){ console.log('page is loaded :)'); // test
9
10    /*
11    $.fn.scrollBottom = function() {
12        return $(document).height() - this.scrollTop() - this.height();
13    };
14    */
15
16	// define vars
17	// var userOS = getMobileOperatingSystem();
18
19	// cache dom elements
20    var $win = $(window);
21    var $doc = $(document);
22
23    var winWidth    = $win.width(),
24        winHeight   = $win.height(),
25        docWidth    = $doc.width(),
26        docHeight   = $doc.height();
27
28	// var $getTheApp      = $('header a.get-the-app');
29    var $page_main_wrap = $('#page_main_wrap, .page-wrap main#main');
30    var $getTheApp = false;
31
32
33	// let's go...
34	//----------------------------------------------------------
35
36
37
38
39
40
41
42/**********************************************************
43 * SLIDER
44 **********************************************************/
45    var $slider = $('body.static-page div.slider'),
46        $carousel = $slider.find('body.static-page div.carousel.carousel-slide'),
47        $formWrap = $('body.static-page #main-search-form-wrap'),
48        $searchForm = $formWrap.find('body.static-page form.search-form');
49
50
51        /*console.log($slider.height());
52        console.log($carousel.height());
53        console.log($formWrap.height());
54        console.log($searchForm.height());*/
55
56
57        /*$carousel.height($searchForm.height());*/
58        /*
59
60        $formWrap.attr('style',
61            'box-sizing:content-box;width:100%!important;'
62        );
63        $searchForm.attr('style',
64            'top:0px!important;width:100%!important;max-width:initial;'
65        );
66        */
67
68
69
70
71/**********************************************************
72 * Set the appropriate link for the mobile app
73 **********************************************************/ 
74	if($getTheApp){
75
76		if(userOS=='Android'){
77			$getTheApp.attr('href',android_appURL);
78		}else if(userOS=='iOS'){
79			$getTheApp.attr('href',iOS_appURL);
80		}else{
81            $getTheApp.attr('href',android_appURL);
82        }
83	}//END if($getTheApp.length)
84
85
86/**********************************************************
87 * Google AdSense
88 **********************************************************/
89
90    /*
91    console.log(docWidth+'x'+docHeight);
92    var $gAd = $('.gAd').width();
93    var $ins_origWidth = $('.gAd ins').width();
94    var $ifr_origWidth = $('.gAd iframe').attr('width');
95    var $img_origWidth = $('.gAd iframe').width();
96    */
97
98
99
100
101    /*
102    $(document).on('ready','aside.side div.adsense', function(){
103
104        $(this).contents().find('body, ins, div, table, thead, tbody, th, tr, td, a, p, span, li, ul').css({
105            'background-color':'#333333!important'
106        });
107    });
108    */
109
110
111/**********************************************************
112 * Trigger based methods and actions
113 **********************************************************/
114
115    /*************************
116     * $doc.RESIZE
117     ************************/
118    if(1==2)
119    $win.resize(function(){
120
121        $win = $(window);
122        $doc = $(document);
123
124        docWidth = $doc.width();
125        docHeight = $doc.height();
126
127        //console.log(docWidth+'x'+docHeight);
128
129    });
130
131
132    /*************************
133     * a > img click prevent default
134     * temp hotfix for an old plugin
135     ************************/
136    var $content_a_img = $page_main_wrap.find('a img').parent();
137    $content_a_img.css('display', 'block'); // also has to be block to float right
138    $content_a_img.click(function(e){
139
140        var href = $(this).attr('href').toLowerCase();
141
142        if( (
143                href.lastIndexOf('.jpg') >= 0 || href.lastIndexOf('.jpeg') >= 0 || href.lastIndexOf('.png') >= 0
144                || href.lastIndexOf('.gif') >= 0
145            )
146            &&( ((href.indexOf('http:') >= 0 || href.indexOf('https:') >= 0) && href.indexOf(domainname) >= 0)
147                || href.indexOf('/') == 0 // cover local relative paths
148            )
149        ){
150
151            e.preventDefault();
152            return true;
153        }
154    });
155
156
157/**********************************************************
158 * Testing some stuff here at the bottom
159 **********************************************************/ 
160
161	/*
162	$(document).on('focusout', 'div.slicknav_menu', function(event){
163  		
164  		$('#glavni_menu').slicknav('close');
165
166  		//event.preventDefault();
167  		//event.stopPropagation();
168  		//return null;
169  	});*/
170
171
172	/*
173	$('#menu').slicknav({
174			prependTo:'#demo1'
175	});
176	*/
177
178});//END $(document).ready

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.