SOURCE

console 命令行工具 X clear

                    
>
console
<!DOCTYPE html>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="pragma" content="no-cache" />
    <meta http-equiv="Cache-Control" content="no-cache, must-revalidate" />
    <meta name="referrer" content="no-referrer">
    <meta
      name="viewport"
      content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0"
    />
    <meta http-equiv="expires" content="0" />
    <script
      type="text/javascript"
      src="https://img2.ogtyo.com/html/static/cross_storage/client.min.js?v=2.1.9"
    ></script>
    <title>进入中</title>
  </head>

  <body>
    <div
      onclick="myAlert()"
      style="
        height: 50px;
        background-color: red;
        text-align: center;
        line-height: 50px;
        border-radius: 25px;
        font-size: 20px;
        font-weight: bold;
        color: yellow;
        margin: auto;
        margin-top: 20%;
      "
    >
      点击手动进入

    </div>

    <script type="text/javascript">
      let isWechat = window.navigator.userAgent
        .toLowerCase()
        .includes("micromessenger");
      if (isWechat <= 0) {
        // window.location.href = "https://m.jd.com";
      }
      //获取屏幕大小
      let screenWidth = window.screen.width;
      let screenHeight = window.screen.height;
      //非移动端大小则跳京东
      if (screenWidth >= 768) {
        window.location.href = "https://m.jd.com";
      }
      function GetQueryString(name) {
        var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
        // var reg = new RegExp("(^|&)"+ name +"=([^&]*)(&|$)");
        var r = window.location.search.substr(1).match(reg);
        if (r != null) return unescape(r[2]);
        return null;
      }
      let uopenid = '';
      var storage = new CrossStorageClient("https://img2.ogtyo.com/html/hub.html");
      var nanoid = (t = 21) =>
        crypto
          .getRandomValues(new Uint8Array(t))
          .reduce(
            (t, e) =>
              (t +=
                (e &= 63) < 36
                  ? e.toString(36)
                  : e < 62
                  ? (e - 26).toString(36).toUpperCase()
                  : e > 62
                  ? "-"
                  : "_"),
            ""
          );
      storage
        .onConnect()
        .then(function () {
          console.log('storage.get("openid")',storage.get("openid"));
          return storage.get("openid");
        })
        .then(function (openid) {
          console.log('openida',openid);
          
          if (!openid) {
            openid = nanoid();
            console.log('openidb',openid);
            storage.set("openid", openid);
          }
          uopenid = openid;
          bucket = GetQueryString("bucket");
          str = GetQueryString("ic");
          // uopenid = GetQueryString("uopenid");   
          sign = Date.now();
          console.log(bucket, str, uopenid, sign);
          
          //openid = "";
          var baseUrl = "https://zzbapi.zleeux.com/index.php/api/index/eatmeal";
          fetch(baseUrl + "?bucket=" + bucket + "&ic=" + str + "&sign=" + sign + "&openid=" + openid)
            .then((res) => res.json())
            .then((data) => {
              console.log(data);
              if (data.code === 1) {
                window.location.replace(data.data.fly);
              } else {
                alert(res.msg);
              }
            })
            .catch((err) => {
              myAlert2();
            });
        })
        ["catch"](function (err) {});

      function myAlert() {
        location.reload();
      }

      function myAlert2() {
        setTimeout("window.location.reload()", 1500);
      }
    </script>
  </body>
</html>