PageSourceSearch

https://www.mybeijingchina.com/js/mobile-first/base.js

js mybeijingchina.com collected 2026-10-02 14:06:09 UTC 2,365 bytes, 46 lines download raw bytes

1self.fetch||(self.fetch=function(e,n){return n=n||{},new Promise(function(t,s){var r=new XMLHttpRequest,o=[],u=[],i={},a=function(){return{ok:2==(r.status/100|0),statusText:r.statusText,status:r.status,url:r.responseURL,text:function(){return Promise.resolve(r.responseText)},json:function(){return Promise.resolve(r.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([r.response]))},clone:a,headers:{keys:function(){return o},entries:function(){return u},get:function(e){return i[e.toLowerCase()]},has:function(e){return e.toLowerCase()in i}}}};for(var c in r.open(n.method||"get",e,!0),r.onload=function(){r.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,function(e,n,t){o.push(n=n.toLowerCase()),u.push([n,t]),i[n]=i[n]?i[n]+","+t:t}),t(a())},r.onerror=s,r.withCredentials="include"==n.credentials,n.headers)r.setRequestHeader(c,n.headers[c]);r.send(n.body||null)})});
2
3function ready(fn){  
4    if(document.addEventListener){      
5        //标准浏览器  
6        document.addEventListener('DOMContentLoaded',function(){  
7            //注销事件,避免反复触发  
8            document.removeEventListener('DOMContentLoaded',arguments.callee,false); 
9            //执行函数   
10            fn();
11        },false);  
12    }else if(document.attachEvent){     
13        //IE浏览器  
14        document.attachEvent('onreadystatechange',function(){  
15            if(document.readyState=='complete'){  
16                document.detachEvent('onreadystatechange',arguments.callee);  
17                //执行函数   
18                fn();  
19            }  
20        });  
21    }  
22}
23
24function  jsGetToPost(url) {
25    let generateHideElement = function (name, value) {
26        let tempInput = document.createElement("input");
27        tempInput.type = "hidden";
28        tempInput.name = name;
29        tempInput.value = value;
30        return tempInput;
31     }
32
33    let orgUrl = url;
34	url = url.split("?");
35    let form = document.createElement("form");
36    document.body.appendChild(form);
37
38    let paraArr = url[1].split("&");
39    for(var i=0;i<=paraArr.length-1;i++){
40		var paraKeyValue = paraArr[i].split("=");
41        form.appendChild(generateHideElement(paraKeyValue[0],paraKeyValue[1]));
42	}
43    form.method = "post";
44    form.action = url[0];
45    form.submit();
46}

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.