/    Sign up×
Community /Pin to ProfileBookmark

Session with cookie …

Hello

I’ve read all thread about a session, and unfortunatelly I can not solve it

My session works on the localhost only, I mean that it works fine if I run it on the one computer ( localhost ). The problem is when I test it on the real server ( WinXP Prof with Apache 2.0.54 + PHP5-as a module)
The problem is:

Every time when the session_start( ) function is called the new session ID is created. It looks like the session ID is not stored in the cookie. I dont know why …

Everything looks all right to me,
1. on the client side ( in browser ) the [b]cookie is Enabled[/b],
2. the [b]php.ini[/b] should be ok,

session.save_handler = files
[b]session.use_cookie = 1[/b]
session.name = PHPSESSID
session.auto_start = 0
session.cookie_lifetime = 0
[b]session.cookie_path = / [/b] ???
[b]session.cookie_domain = [/b] ???
[b]session.use_trans_sid = 0[/b]

Could you give me some advise , what should I do ( check ) next to solve it

Thanks in advance

Andrzej

to post a comment
PHP

1 Comments(s)

Copy linkTweet thisAlerts:
@avaDec 02.2005 — Try checking the following in the PHP.ini

[COLOR=DarkRed]session.save_path [/COLOR]

Should point to a valid location on the server

[COLOR=DarkRed]session.gc_maxlifetime [/COLOR]

This should be a high number (it's 1440 with me)

[COLOR=DarkRed]session.cache_expire [/COLOR]

Should be a high number (it's 180 with me)
×

Success!

Help @andrzej 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 6.1,
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: @meenaratha,
tipped: article
amount: 1000 SATS,

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

tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,
)...