PageSourceSearch

https://pressair.ru/netcat_template/template/115/js/psp.js?home=1

js pressair.ru collected 2026-10-08 06:01:05 UTC 3,731 bytes, 127 lines download raw bytes

1//pagespeed routine
2var isMobile = false;
3var aIncJs = ['null.js'];
4var pspFired = false;
5const isSmallMedia = matchMedia('(max-width: 768px)');
6
7if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
8  isMobile = true;
9}
10if (isSmallMedia.matches) isMobile = true;
11
12
13window.addEventListener('scroll', () => {
14  if (pspFired === false) {
15    pspFired = true;
16
17    setTimeout(() => {
18
19      /*includeCss('/css/swiper.min.css');*/
20
21      loadScript('https://www.google.com/recaptcha/api.js?render=6Le_O88ZAAAAALJZIDqRWuokaBDrCvGVnO_CQJ2l', function() {
22        grecaptcha.ready(function() {
23          grecaptcha.execute('6Le_O88ZAAAAALJZIDqRWuokaBDrCvGVnO_CQJ2l', {
24            action: 'validate_captcha'
25          }).then(function(token) {
26
27            var rc = document.getElementById('g-recaptcha-response');
28            if (rc) rc.value = token;
29
30            var rc1 = document.getElementById('g-recaptcha-response-1');
31            if (rc1) rc1.value = token;
32
33          })
34        })
35      });
36      
37
38      (function() {
39        var widget_id = '5idsbcTgJv';
40        var s = document.createElement('script');
41        s.type = 'text/javascript';
42        s.async = true;
43        s.src = '//code.jivosite.com/script/widget/' + widget_id;
44        var ss = document.getElementsByTagName('script')[0];
45        ss.parentNode.insertBefore(s, ss);
46      })();
47
48      
49      includeJs('https://api-maps.yandex.ru/v3/?apikey=e0c10e1d-a5b6-425d-98f6-c54504916c27&lang=ru_RU');
50
51      includeJs('/netcat_template/template/115/js/jquery.fileupload.js');
52
53      loadScript('/netcat_template/template/115/js/mCustomScrollbar.js', function() {
54        // Your code to run AFTER the JS file loads
55        jQuery(".tpl-block-comparision-original").mCustomScrollbar({
56          axis: "x",
57          theme: "dark-3",
58          advanced: {
59            autoExpandHorizontalScroll: true
60          },
61          callbacks: {
62            onCreate: function() {
63              jQuery(this).find(".item").css("width", jQuery(this).width());
64            },
65            onBeforeUpdate: function() {
66              jQuery(this).find(".item").css("width", jQuery(this).width());
67            }
68          }
69        });
70      });
71
72    }, 1000)
73  }
74});
75
76function includeCss(hrefCss) {
77  var head = document.getElementsByTagName('head')[0];
78  var link = document.createElement('link');
79  link.id = 'css_'+str2HtmlId(hrefCss);
80  link.rel = 'stylesheet';
81  link.type = 'text/css';
82  link.href = hrefCss;
83  link.media = 'all';
84  head.appendChild(link);
85}
86
87function includeJs(jsFilePath, dataname, dataval) {
88  var js = document.createElement("script");
89
90  if (aIncJs.indexOf(jsFilePath) > 0) return 0; //once load
91  aIncJs.push(jsFilePath);
92
93  js.type = "text/javascript";
94  js.src = jsFilePath;
95  js.id = 'js_'+str2HtmlId(jsFilePath);
96
97  if (dataname !== undefined) {
98    let a = document.createAttribute(dataname);
99    a.value = dataval;
100    js.setAttributeNode(a);
101  }
102  document.body.appendChild(js);
103  console.log('append js' + jsFilePath);
104}
105
106function loadScript(url, callback) {
107  const script = document.createElement('script');
108  script.src = url;
109  script.id = 'js_'+str2HtmlId(url);
110
111  // This runs after the file is loaded
112  script.onload = () => {
113    console.log(url+' loaded successfully!');
114    callback();
115  };
116
117  // Handle potential loading errors
118  script.onerror = () => {
119    //console.error('Error loading script:', url);
120  };
121
122  document.head.appendChild(script);
123}
124function str2HtmlId(str){
125  const regexStrict = /^[A-Za-z][\w\-\:\.]*$/;
126  return str.replace(regexStrict, "");
127}

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.