Deleting Cookies

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
dethron
Forum Contributor
Posts: 370
Joined: Sat Apr 27, 2002 11:39 am
Location: Istanbul

Deleting Cookies

Post by dethron »

Is there a way to delete cookie instead of filling with nothing? :oops:
Jim
Forum Contributor
Posts: 238
Joined: Fri Apr 19, 2002 5:26 am
Location: Near Austin, Texas

Post by Jim »

Do you have an expiration set for the cookie?

If you do, you can just set another cookie with an expiration value of the exact opposite (i.e. if the original expiration is 2400, set the next one to -2400).

I think this is right. If not, someone please correct me.

Good luck!
dusty
Forum Contributor
Posts: 122
Joined: Sun Apr 28, 2002 9:52 pm
Location: Portsmouth, VA

Post by dusty »

set the cookie to expire in the past.
Post Reply