[Util] -- cookie

Recommended for you: Get network issues from WhatsUp Gold. Not end users.

Take that


Before introducing file:

Method of use:

//Set cookie
CookieUtil.set("name", "xiaoMo");
CookieUtil.set("util", "cookie");

//Read cookie
CookieUtil.get("name");
CookieUtil.get("util");

//Delete cookie
CookieUtil.unset("name");
CookieUtil.unset("util");

//Set the cookie include path, domain, expiration date
CookieUtil.set("name", "xiaoMo", '/path1/path2/', "www.abc.com", new Date('January 12,2015'));

//Delete the top set of cookie
CookieUtil.unset("name", '/path1/path2/', "www.abc.com");

//Set the safety cookie
CookieUtil.set("name", "xiaoMo", null, null, null, true);

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download

Posted by Justin at November 18, 2013 - 1:13 PM