PageSourceSearch

https://shop.megalos.co.jp/js/sys/abtest.js

js megalos.co.jp collected 2026-10-02 04:27:58 UTC 2,491 bytes, 69 lines download raw bytes

1var ecblib = ecblib || {};
2ecblib.abtest = ecblib.abtest || {};
3
4(function () {
5    var _abtest = ecblib.abtest;
6
7    var execTime = new Date();
8    _abtest.loadABtest = true;
9    var ua = (function () {
10        return {
11            isFirefox: 'MozAppearance' in document.documentElement.style,
12            isChrome: navigator.userAgent.toLowerCase().search(/chrome/) != -1,
13            isSafari: !window.chrome && 'WebkitAppearance' in document.documentElement.style,
14            isAndroid: navigator.userAgent.toLowerCase().search(/android/) != -1
15        };
16    })();
17
18    _abtest.saveBlockClickLog = saveBlockClickLog;
19    function saveBlockClickLog(blockId) {
20        var now = new Date();
21        if (now.getTime() - execTime.getTime() > 500) {
22            execTime = now;
23            if (ua.isChrome || ua.isFirefox || ua.isSafari || ua.isAndroid) {
24                jQuery.ajax({
25                    url: "abtest/blockclick.aspx",
26                    async: false,
27                    timeout: 1000,
28                    cache: false,
29                    type: "post",
30                    data: {
31                        blockId: blockId
32                    }
33                });
34            } else {
35                jQuery.ajax({
36                    url: "abtest/blockclick.aspx",
37                    cache: false,
38                    type: "post",
39                    data: {
40                        blockId: blockId
41                    }
42                });
43            }
44        }
45    }
46    jQuery(document).ready(function () {
47        if ("blockIdList" in window) {
48            var blockIds = blockIdList.split(",");
49            jQuery.each(blockIds, function (index, blockId) {
50                var blockName = "#block_of_" + blockId;
51                jQuery(blockName).delegate("a:not(.js-item-history-link,.js-logout-link)", "click", {
52                    blockId: blockId
53                }, function (event) {
54                    saveBlockClickLog(event.data.blockId);
55                });
56                jQuery(blockName).delegate("form", "submit", {
57                    blockId: blockId
58                }, function (event) {
59                    saveBlockClickLog(event.data.blockId);
60                });
61                jQuery(blockName).delegate("input[type=button]", "click", {
62                    blockId: blockId
63                }, function (event) {
64                    saveBlockClickLog(event.data.blockId);
65                });
66            });
67        }
68    });
69}());

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.