⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cookie.js

📁 一个非常适合初学者入门的有关c++的文档
💻 JS
字号:
function getCookie(name) {
  var cname = name + "=";
  var dc = document.cookie;
              if (dc.length > 0) {
    begin = dc.indexOf(cname);
               if (begin != -1) {
      begin += cname.length;
                   end = dc.indexOf(";", begin);
      if (end == -1) end = dc.length;
        return unescape(dc.substring(begin, end));
        }
	}
}


function setCookie(index) {
        document.cookie = "chunk=" + index + "; expires=Tuesday, 01-Jan-34 08:00:00 GMT; path=/";
      	top.location.href = "INDEX.HTM"
        }
function setChunknr(index) {
        document.cookie = "chunk=" + index + "; expires=Tuesday, 01-Jan-34 08:00:00 GMT; path=/";
        top.frames[1].focus();
        }

function setChunk(index) {
                var chunk = getCookie("chunk");
                if (index != chunk){
                document.cookie = 'chunk=' + index + '; expires=Tuesday, 01-Jan-34 08:00:00 GMT; path=/';
                if (top.location.href.indexOf('MAGAZINE') == -1) {top.location.href = "INDEX.HTM";}
                        else {top.location.reload();}
                } else {top.frames[1].focus();}
	   }

function setImgAlert(index) {
       document.cookie = "alertv5=" + index + "; expires=Tuesday, 01-Jan-34 08:00:00 GMT; path=/";
        }

function setNavbar(index) {
		var nav = getCookie("nav");
		if (index != nav){
       			document.cookie = 'nav=' + index + '; expires=Tuesday, 01-Jan-34 08:00:00 GMT; path=/';
			top.location.reload();
                } else {top.frames[1].focus();}
	   }

function setImage(index) {
		var nav = getCookie("image");
		if (index != image){
       document.cookie = "image=" + index + "; expires=Tuesday, 01-Jan-34 08:00:00 GMT; path=/";}
        else {top.frames[1].focus();}

}

function setMag(index) {
       document.cookie = "mag=" + index + "; path=/";
}

function setCheck(index) {
       document.cookie = "check=" + index + "; path=/";
	   }

function setSearchCookie(type) {
        document.cookie = "searchType=" + type + "; expires=Tuesday, 01-Jan-34 08:00:00 GMT; path=/;";
        }

function setCurrentMax(index) {
       document.cookie = "Max=" + index + "; path=/";
	   }



var nav = getCookie('nav');
var chunk = getCookie('chunk');
var image = getCookie('image');
if(image == null)
{setImage('Image3');}
if(chunk == null)
{setChunknr('Item');}
if(nav == null)
{setNavbar('140');}

// Copyright 1998 Videomation, Inc. All Rights Reserved.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -