PageSourceSearch

https://www.tel.co.jp/assets/js/cookie.js

js tel.co.jp collected 2026-10-01 10:42:13 UTC 932 bytes, 38 lines download raw bytes

1//初期表示は表示
2document.getElementById("cookie").style.visibility = "visible";
3
4function cookiehide() {
5  const cookieElement = document.getElementById("cookie");
6  if (cookieElement.style.visibility == "visible") {
7    // hiddenで非表示
8    cookieElement.style.visibility = "hidden";
9  }
10}
11
12function cookieagree() {
13  //cookie登録する
14  document.cookie = 'tel_add=cookie_agree; path=/; max-age=15552000';
15}
16
17
18function getCookieArray() {
19  var arr = new Array();
20  if (document.cookie != '') {
21    var tmp = document.cookie.split('; ');
22    for (var i = 0; i < tmp.length; i++) {
23      var data = tmp[i].split('=');
24      arr[data[0]] = decodeURIComponent(data[1]);
25    }
26  }
27  return arr;
28}
29
30var arr = getCookieArray();
31var value = arr['tel_add'];
32
33if (value == 'cookie_agree') {
34  cookiehide();
35}
36
37const cookieBtn = document.querySelector('.cookie__close');
38cookieBtn.addEventListener("click", cookiehide, false);

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.