PageSourceSearch

https://chart.cnyes.com/js/MeasureCnyes.js

js cnyes.com collected 2026-09-24 08:51:30 UTC 2,944 bytes, 110 lines download raw bytes

1
2
3var isFundCnyes = (location.hostname.toString()=="fund.cnyes.com"||location.hostname.toString()=="fund-cdn.cnyes.com");
4
5var pathname = location.pathname;
6
7
8
9
10function GetCn_new(a) {
11    if (a == null) return '';
12    var o = a.indexOf('CN=') + 3;
13    e = a.indexOf(';', o);
14    if (e == -1) e = a.indexOf('&', o);
15    if (e == -1) e = a.length;
16    return a.substring(o, e);
17}
18
19
20function trackClick(p01, p1, p2, p3, p4, p5) {
21    var url = p01;
22    ga(p1, p2, p3, p4, p5, {
23        hitCallback: function() {
24			if (url == null)  {
25			} else {
26            window.location = url;
27			}
28        }
29    })
30
31    return false;
32}
33
34  // 2017-02-20 tracking code
35    function getCookie(cname) {
36        var name = cname + "=";
37        var ca = document.cookie.split(';');
38        for (var i = 0; i < ca.length; i++) {
39            var c = ca[i];
40            while (c.charAt(0) == ' ') {
41                c = c.substring(1);
42            }
43            if (c.indexOf(name) == 0) {
44                return c.substring(name.length, c.length);
45            }
46        }
47        return "";
48    }
49
50    var t_mail
51    var t_msg
52    try
53    {
54        t_mail = getCookie('AicMember2').split('=')[1].split('&')[0]
55    }
56    catch (err) {
57        t_mail = ''
58    }
59
60
61    var _paq = _paq || [];
62    function transition() {
63
64        if (t_msg == undefined) {
65
66        }
67        else {
68
69            var emailRegxp = /^([\w]+)(.[\w]+)*@([\w]+)(.[\w]{2,3}){1,2}$/;
70             if (emailRegxp.test(t_msg) != true) {
71                         t_msg = '';
72             }
73            //console.log('登入帳號 ' + t_msg)
74            clearTimeout(mytimeout)
75
76            if (t_msg == '') {
77              //console.log('未登入')
78                //未登入
79                _paq.push(['setCookieDomain', '*.cnyes.com']);
80                _paq.push(["setDomains", ["*.cnyes.com", "*.blog.cnyes.com", "*.cdn.cnyes.com", "*.fundsyes.com"]]);
81                _paq.push(['trackPageView']);
82                _paq.push(['enableLinkTracking']);
83
84                
85
86            }
87            else {
88               //console.log('已登入')
89                //已登入
90
91                _paq.push(['setCookieDomain', '*.cnyes.com']);
92                _paq.push(["setDomains", ["*.cnyes.com", "*.blog.cnyes.com", "*.cdn.cnyes.com", "*.fundsyes.com"]]);
93                _paq.push(['setCustomVariable', '2', 'email', t_msg.toLowerCase()]);
94                _paq.push(['setUserId', t_msg.toLowerCase()]);
95                _paq.push(['trackPageView']);
96                _paq.push(['enableLinkTracking']);
97
98               
99            }
100            //-->
101
102        }
103    }
104    //var mytimeout = setInterval(transition, 10);
105	
106    var host = location.host;
107	var path = location.pathname+location.search
108	if (host == 'stage.cnyes.com') {
109		window.location = 'https://www.cnyes.com' + path;
110	}

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.