Why we are used setMaxAge() and getMaxAge() in Cookies ?
Question:
Why we are used setMaxAge() and getMaxAge() in Cookies ?
Question:Why we are used setMaxAge() and getMaxAge() in Cookies ?
Answer
The "public void setMaxAge(int expiry)" method sets the maximum age of the cookie. After the specified time the cookie will be deleted.
The "public int getMaxAge()" method will return the maximum specified age of the cookie.
By:Jalees Date:
Why we are used setMaxAge() and getMaxAge() in Cookies ?