首页 > 代码库 > cookie相关内容

cookie相关内容

----客户端删除cookie

 <script type="text/javascript">
            
            function DelCookie() {
                var name = "user";
                var exp = new Date();
                exp.setTime(exp.getTime() - 1);
                document.cookie = name += "=;expires=" + exp.toGMTString();
          
            location.href = "http://www.mamicode.com/Login.aspx";
        }
    </script>

cookie相关内容