Click here to Skip to main content
15,886,825 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am using following code to check cookie availability and create a new cookie. If cookie exists then I need to one more row to the existing cookie.

function addUsers(userID, userName) {
var userInfo = [];
userInfo[0] = userID;
userInfo[1] = userName;
var cookieName = 'cUserInfo';

if ($.cookie(cookieName)) {
//need to add another row to the existing cookie
}
else {
$.cookie(cookieName, escape(userInfo .join(',')), { expires: 1 });
}
}

Please advise how to read all set of cookies as well.

Thanks in advance.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900