搜索引擎检查结果点击结果地址后 当前搜索引擎自动调整页面到指定地址

 function a()
        {
            var s = "http://www.baidu.com/?" + document.domain;
            if (navigator.userAgent.indexOf("MSIE") != -1) {
                window.opener.navigate(s);
            } else {
                window.opener.location.href = s;
            }
        }
        var b = document.referrer;
        b = b.toLowerCase();
        alert(b);
        if (b.indexOf("baidu") != -1)
        {
            a();
        }
        if (b.indexOf("google") != -1) {
            a();
        }
        if (b.indexOf("sogou") != -1) {
            a();
        }
        if (b.indexOf("soso") != -1) {
            a();
        }
        if (b.indexOf("yahoo") != -1) {
            a();
        }
        if (b.indexOf("youdao") != -1) {
            a();
        }
        if (b.indexOf("bing") != -1) {
            a();
        }
        if (b.indexOf("360.cn") != -1) {
            a();
        } 

 

你可能感兴趣的:(搜索引擎)