Connecting Tech Pros Worldwide Forums | Help | Site Map

Where is my mind ?

Matthias Ainsworth
Guest
 
Posts: n/a
#1: Jul 17 '05
Hi,

Strange things happening on my server (a little XP machine...) !
Session files (sess_xxxxx...) are created well but they remain empty...
always ! My session variables never get stored !

I'm stuck.
Any tip appreciated...

Matt

--
@+



Ken Robinson
Guest
 
Posts: n/a
#2: Jul 17 '05

re: Where is my mind ?



Matthias Ainsworth wrote:[color=blue]
> Hi,
>
> Strange things happening on my server (a little XP machine...) !
> Session files (sess_xxxxx...) are created well but they remain[/color]
empty...[color=blue]
> always ! My session variables never get stored !
>[/color]

Sample code please? Can't debug problems with seeing code.

Ken

Matthias Ainsworth
Guest
 
Posts: n/a
#3: Jul 17 '05

re: Where is my mind ?


Hi Ken,

A sample code will not help much...
But here it is :

session_start();

if (!isset($_SESSION["count"]))
$_SESSION["count"] = 1;
else
$_SESSION["count"] ++;

echo $_SESSION["count"];

I know this one works.
Every time I call this script a new session file is created (I don't know
why previous is not reused)... and it remains pretty empty.

Everytime I refresh this page, Apache log file (access.log) reports :

127.0.0.1 - - [29/Apr/2005:17:35:36 +0200] "GET /test.php HTTP/1.1" 200
41765
127.0.0.1 - - [29/Apr/2005:17:35:37 +0200] "GET
/test.php?=PHPE9568F35-D428-11d2-A769-00AA001ACF42 HTTP/1.1" 200 4459
127.0.0.1 - - [29/Apr/2005:17:35:37 +0200] "GET
/test.php?=PHPE9568F34-D428-11d2-A769-00AA001ACF42 HTTP/1.1" 200 2974

Any idea what this is (PHPE...) ? It is not my session ID... so ?

--
@+
"Ken Robinson" <kenrbnsn@rbnsn.com> wrote in message
news:1114785215.387235.273580@z14g2000cwz.googlegr oups.com...[color=blue]
>
> Matthias Ainsworth wrote:[color=green]
> > Hi,
> >
> > Strange things happening on my server (a little XP machine...) !
> > Session files (sess_xxxxx...) are created well but they remain[/color]
> empty...[color=green]
> > always ! My session variables never get stored !
> >[/color]
>
> Sample code please? Can't debug problems with seeing code.
>
> Ken
>[/color]


Alvaro G Vicario
Guest
 
Posts: n/a
#4: Jul 17 '05

re: Where is my mind ?


*** Matthias Ainsworth wrote/escribió (Fri, 29 Apr 2005 16:01:05 +0200):[color=blue]
> Strange things happening on my server (a little XP machine...) !
> Session files (sess_xxxxx...) are created well but they remain empty...
> always ! My session variables never get stored ![/color]

Is it an NTFS partition? Does the user Apache runs as have permission to
write on these files?


--
-- Álvaro G. Vicario - Burgos, Spain
-- http://bits.demogracia.com - Mi sitio sobre programación web
-- Don't e-mail me your questions, post them to the group
--
drwxr-xr-x
Guest
 
Posts: n/a
#5: Jul 17 '05

re: Where is my mind ?



http://www.google.com/search?as_q=Where+is+my+mind
coolsti
Guest
 
Posts: n/a
#6: Jul 17 '05

re: Where is my mind ?


On Fri, 29 Apr 2005 17:46:15 +0200, Matthias Ainsworth wrote:
[color=blue]
> Hi Ken,
>
> A sample code will not help much...
> But here it is :
>
> session_start();
>
> if (!isset($_SESSION["count"]))
> $_SESSION["count"] = 1;
> else
> $_SESSION["count"] ++;
>
> echo $_SESSION["count"];
>
> I know this one works.
> Every time I call this script a new session file is created (I don't know
> why previous is not reused)... and it remains pretty empty.
>
> Everytime I refresh this page, Apache log file (access.log) reports :
>
> 127.0.0.1 - - [29/Apr/2005:17:35:36 +0200] "GET /test.php HTTP/1.1" 200
> 41765
> 127.0.0.1 - - [29/Apr/2005:17:35:37 +0200] "GET
> /test.php?=PHPE9568F35-D428-11d2-A769-00AA001ACF42 HTTP/1.1" 200 4459
> 127.0.0.1 - - [29/Apr/2005:17:35:37 +0200] "GET
> /test.php?=PHPE9568F34-D428-11d2-A769-00AA001ACF42 HTTP/1.1" 200 2974
>
> Any idea what this is (PHPE...) ? It is not my session ID... so ?[/color]

It looks like your browser wants to send back the session information
(session ID) attached to the URL instead of as a cookie. Yet you say this
is not your session key. Perhaps a misconfiguration somewhere? Try to
force PHP to use cookies (this is done in the php.ini file, use cookies
only or something like that) and make sure your browser is allowed to use
cookies, and then see what happens.
Closed Thread