/    Sign up×
Community /Pin to ProfileBookmark

Physical location of cookies created by setCookie() function, and expiry

I am not able to locate the cookies created by the setCookie function. They are not in the standard IE folder where temporary Internet files and cookies are placed. Does anyone know where I search, or how I trace them?

Also, I created cookies using this command:

[CODE]
$string_to_check = $type.”_”.$pid;
setCookie(“$string_to_check”, “1”, time()+30*1);
[/CODE]

The cookie doesn’t expire in 30 seconds – in fact, it doesn’t seem to expire at all.

One of the reasons that I want to see the actual cookies is to see what the expiration time is being set to.

I’d be quite grateful for any pointers. Thank you very much for your time!

to post a comment
PHP

5 Comments(s)

Copy linkTweet thisAlerts:
@sitehatcheryAug 25.2007 — I use firefox and add the web developer addon. It gives a very simple interface to add, delete and edit cookies.
Copy linkTweet thisAlerts:
@knkkauthorAug 26.2007 — Also, I just noticed that my code works in FF but not in IE. That is, the cookie expires in FF in 30s, but not in IE. But sitehatchery, I do not see the actual cookie in FF either (when I do Tools -> Options -> Show Cookies).
Copy linkTweet thisAlerts:
@knkkauthorAug 26.2007 — Well, I [I]am[/I] able to see the actual cookie in FF and in IE now (though I did nothing different ). I guess it was always visible in FF - it was just expiring in 30s, before I could see it. In IE, however, it is showing up suddenly now, and this is the text of the cookie file:

events_3525

1

www.mydomain.com/

1536

3949138304

29878276

3661621984

29878196

*

Would anyone know what all those numbers mean? Thank you for your time.
Copy linkTweet thisAlerts:
@knkkauthorAug 26.2007 — I just figured that my IE cookie expires in about 9 hours and 33 minutes though I set it to expire in 30 seconds. Cannot figure out why ?.
Copy linkTweet thisAlerts:
@knkkauthorAug 26.2007 — Okay, so I figured this out. The time zones in the client machine and the server were different. I set them both to the exact same time and zone, and IE too started working.

For anyone who needs to do the same on a Linux box (change the time zone):

http://www.linuxsa.org.au/tips/time.html
×

Success!

Help @knkk spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.13,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...