Welcome  ,
Interview Questions >> PHP >> How to destroy a cookie?
Next Question Previous Question

How to destroy a cookie?

  Joseph Ranjan wrote ...
To destroy a cookie we need to set time in past.


// set the expiration date to one hour ago

setcookie ("TestCookie", "", time() - 3600);

Login to write answer for this question !
Want to place your ads in this website ?
50USD Per Month for single placement. Contact Us
All Rights Reserved . Developed by SJRANJAN