3
Answers

Cookie in Java Script

kalpana jaiswal

kalpana jaiswal

6y
213
1
can we store multiple value in cooking through javascript ???
like as  i am trying to do in below code segment...
 
if (document.frmRegistration.txtName.value!="" && document.frmRegistration.txtAge.value!="")
{
cookieName= escape(document.frmRegistration.txtName.value) + ";";
cookieAge=escape(document.frmRegistration.txtAge.value)+";";
document.cookie="name="+cookieName+";age="+cookieAge+";";
document.write("Name="+cookieName+"Age="+cookieAge);


Answers (3)