Toggle navigation
Dashboard
Dashboard Tracker
Add / Edit My Forums
System Announcements
Discussion
Active Thread Feed
Top Threads Today
Top Threads This Week
Top Threads Library
Go!
View All
View All
Login
Logout
Home
Forums Index
Server Side
/
PHP Server Side Scripting
7:30 am Aug 11, 2026
This page requires javascript.
Forum Moderators:
coopster
Message Too Old, No Replies
PHP - deleting cookie?
Crump
Msg#:1304534
8:59 pm on Mar 17, 2006
(gmt 0)
What is the best way to delete a cookie in PHP? By changing the expiration date to something in the past? or by setting the value to nothing ("")?
IamStang
Msg#:1304535
2:21 am on Mar 18, 2006
(gmt 0)
From what I have read on the subject, "changing the expiration date to something in the past" is the best method.
Mr_Fern
Msg#:1304536
10:21 am on Mar 18, 2006
(gmt 0)
stang's right. simply setting it to "" doesn't delete it, just gives it the value of empty string
coopster
Msg#:1304537
8:10 pm on Mar 18, 2006
(gmt 0)
Examples can be found in the PHP manual pages for
setcookie()
[php.net].
Join The Conversation
Register
For Free! -
Become a
Pro Member
!
See forum categories
-
Enter the Forum
Moderators and Top Contributors
Moderator List
| Top Contributors:
This Week
,
This Month
,
Jul
,
Jun
,
Archive
,
Top 100 All Time
,
Top Voted Members
Hot Threads This Week
August 2026 Google Search Observations
AdSense Earnings and Observations - August 2026
Booking Feels Google AI Effects - Plans SEO decline
IbouBot
EU AI Transparency Rules Now in Effect
Do you still build external links in 2026?
July 2026 Google Search Observations
How has AI changed your work?
Home
Forums Index
Server Side
/
PHP Server Side Scripting
7:30 am Aug 11, 2026