Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


when will cookie information destroy?

Answers were Sorted based on User's Feedback



when will cookie information destroy?..

Answer / balakrishna

cookie is a"small amount of data" that is set by the server
on the client.

we have setmaxAge() for destroy cookie.

1.cookie.setMaxAge(100)-->100 sec
If we set the max age of a cookie to 100 sec,the browser
holds the cookie for 100 sec even if we close the browser.

2.If we set max age value to negative value the browser hold
the cookie till we close the browser.

3.If we use setMaxAge(0) the browser will arase the cookie.

Is This Answer Correct ?    11 Yes 0 No

when will cookie information destroy?..

Answer / suresh

cookie is small amount of data and it's store on the client
machine that is your browser machine

..Developer to create cookie and set the life time of cookie
on our web application
example

cookie.setMaxAge(1000);

the cookie available in 1000ms

Is This Answer Correct ?    11 Yes 3 No

when will cookie information destroy?..

Answer / ravikiran

when we disable the cookies inside the client browser or if
the cookie age is finished which is set as
cookie.setMaxAge(mins*secs);

Is This Answer Correct ?    1 Yes 0 No

when will cookie information destroy?..

Answer / ramu

cookie is small "amount of a data", the cookie is set by
client & server.
cookie is setmaxAge() .
For ex:-
1.cookie.setMaxAge(100)-->100 sec
If we set the max age of a cookie to 100 sec,the
browser
holds the cookie for 100 sec even if we close the browser.

2.If we set max age value to negative value the browser hold
the cookie till we close the browser.

3.If we use setMaxAge(0) the browser will arase the cookie.

Is This Answer Correct ?    1 Yes 0 No

when will cookie information destroy?..

Answer / manisha

Along with setMaxAge() method the gae of the cookie can be
set in web.xml

Is This Answer Correct ?    0 Yes 0 No

when will cookie information destroy?..

Answer / bijaya

Cookie is a small unit of information created at the server and is maintained at the client side.
This information is managed by HTTP protocol.
The cookie will be exiating in the client for the time period specified by the MaxAge property,
So,to destroy the the cookie we have to set the MaxAge to 0.
Ex:
cookie.setMaxAge(0);

Is This Answer Correct ?    0 Yes 0 No

when will cookie information destroy?..

Answer / ravikiran

when we disable the cookies inside the client browser or if
the cookie age is finished which is set as
cookie.setMaxAge(mins*secs);

Is This Answer Correct ?    0 Yes 2 No

Post New Answer

More Servlets Interview Questions

Why the concept of single thread model interface is used?

0 Answers  


Which is better approach among four(HttpSession,cookie,URL Rewriting, Hidden Fields) Session Tracking technic's ? Why ?

3 Answers   L&T,


program for RequestDispatcher in servlets?

3 Answers   Wipro,


What is servlet and its advantages?

0 Answers  


What compiler do not do if we create our own constructor?

5 Answers   HCL,


Explain the difference between generic servlet and http servlet?

0 Answers  


What do you mean by default initialization in java servlet?

0 Answers  


Explain their methods? Tell me their parameter names also have you used threads in servlet?

0 Answers  


Who is responsible to create the object of servlet?

0 Answers  


What is a servlet?

0 Answers  


What is SingleThreadModel interface?

0 Answers  


java.lang.IllegalArgumentException: The path of an ForwardConfig cannot be null while working with struts it displayed pls very ungent

3 Answers   IBM,


Categories