PageSourceSearch

https://9x.ru/media/cache/cache_assets/376b99a5a7f62039f624adb4cc2c4bdf/assets/js_1777.js

js 9x.ru collected 2026-10-02 02:06:42 UTC 2,403 bytes, 108 lines download raw bytes

1var JS_1777 = {
2    Interface: {},
3    isUndefined: function (v) {
4        if (typeof v === 'undefined') {
5            return true;
6        }
7        else {
8            return false;
9        }
10    },
11    getValue: function (data, key, defaultValue) {
12
13        if (!JS_1777.isUndefined(data[key])) {
14            return data[key];
15        }
16
17        return defaultValue;
18    },
19    Validator: {
20        city_phone: function (value) {
21            var num = value.replace(/[^0-9]/g, '');
22
23            if (num.length < 6) {
24                return false;
25            }
26            else {
27                return true;
28            }
29        },
30        mobile_phone: function (value) {
31            var num = value.replace(/[^0-9]/g, '');
32
33            if (num.length < 11) {
34                return false;
35            }
36            else {
37                return true;
38            }
39        }
40    },
41};
42
43JS_1777.Array = {
44    removeItem: function (arr, removeItem) {
45        return $.grep(arr, function (value, key) {
46            return key != removeItem;
47        });
48    }
49};
50
51JS_1777.Interface = {
52    linkPressed: false,
53    isLinkPressed: function () {
54        console.log(this.linkPressed);
55        if (!this.linkPressed) {
56            this.linkPressed = true;
57
58            setTimeout(function () {
59                JS_1777.Interface.linkPressed = false;
60            }, 1000);
61
62            return true;
63        }
64        else {
65            return false;
66        }
67    }
68};
69
70JS_1777.localStorage = {
71    setItem: function (key, value) {
72        if (localStorage) {
73            localStorage.setItem(key, value);
74        }
75    },
76    getItem: function (key) {
77        if (localStorage) {
78            return localStorage.getItem(key);
79        }
80        return null;
81    },
82
83};
84
85JS_1777.PATHS = {};
86
87JS_1777.getCookie = function(key) {
88   var ck = document.cookie;
89   if (typeof(ck) == "undefined"){
90      return "";
91   }
92   var i = ck.indexOf(key + "=");
93   var j = ck.indexOf(";", i);
94   var st;
95   if (i < 0){
96      return "";
97   }
98   if (j < 0){
99      return ck.substring(i + key.length + 1);
100   } else {
101      return ck.substring(i + key.length + 1, j);
102   }
103};
104
105JS_1777.setCookie = function(key, value) {
106   document.cookie = key+"="+value+";path=/;domain=;expires=Tue, 1 Jan 2050 01:11:11 GMT';";
107};
108

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.