Connecting Tech Pros Worldwide Forums | Help | Site Map

Phantom Session Variables

Ben
Guest
 
Posts: n/a
#1: Jul 17 '05
Hello,

My $_SESSION variables disappear and reappear. It's not just
a matter of not caching the page. I usually have to press the Refresh
button about 3 times to get the page to remember the variables. Sometimes
refreshing again will cause the variables to disappear again. PHPSESSID
will often be empty after using session_start().
Any ideas on how to limit this action?

Thanks, Ben



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

re: Phantom Session Variables


This is interesting. According to phpinfo, 'session.save_path' =
'/nfs/php-sessions' . According to php, the directory '/nfs/php-sessions'
doesn't exist. Could this have something to do with it?

[color=blue]
> Hello,
>
> My $_SESSION variables disappear and reappear. It's not just
> a matter of not caching the page. I usually have to press the Refresh
> button about 3 times to get the page to remember the variables. Sometimes
> refreshing again will cause the variables to disappear again. PHPSESSID
> will often be empty after using session_start().
> Any ideas on how to limit this action?
>
> Thanks, Ben[/color]


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

re: Phantom Session Variables


Turns out it's not just the session variables. No pHp scripts run
consistently. When I press refresh, sometimes a directory will exist and
sometimes it won't. Something is screwy. Is it the server or pHp setup?

[color=blue]
> Hello,
>
> My $_SESSION variables disappear and reappear. It's not just
> a matter of not caching the page. I usually have to press the Refresh
> button about 3 times to get the page to remember the variables. Sometimes
> refreshing again will cause the variables to disappear again. PHPSESSID
> will often be empty after using session_start().
> Any ideas on how to limit this action?
>
> Thanks, Ben[/color]


Westcoast Sheri
Guest
 
Posts: n/a
#4: Jul 17 '05

re: Phantom Session Variables


Ben wrote:
[color=blue]
> Turns out it's not just the session variables. No pHp scripts run
> consistently. When I press refresh, sometimes a directory will exist and
> sometimes it won't. Something is screwy. Is it the server or pHp setup?
>[color=green]
> > Hello,
> >
> > My $_SESSION variables disappear and reappear. It's not just
> > a matter of not caching the page. I usually have to press the Refresh
> > button about 3 times to get the page to remember the variables. Sometimes
> > refreshing again will cause the variables to disappear again. PHPSESSID
> > will often be empty after using session_start().
> > Any ideas on how to limit this action?
> >
> > Thanks, Ben[/color][/color]

Post the exact code, if you want me to try to run it on my server.


R. Rajesh Jeba Anbiah
Guest
 
Posts: n/a
#5: Jul 17 '05

re: Phantom Session Variables


[Top-post fixed]

"Ben" <ben@pyramidlabel.com> wrote in message news:<6d3sd.9182$_3.107336@typhoon.sonic.net>...[color=blue][color=green]
> > Hello,
> >
> > My $_SESSION variables disappear and reappear. It's not just
> > a matter of not caching the page. I usually have to press the Refresh
> > button about 3 times to get the page to remember the variables. Sometimes
> > refreshing again will cause the variables to disappear again. PHPSESSID
> > will often be empty after using session_start().
> > Any ideas on how to limit this action?
> >[/color]
> Turns out it's not just the session variables. No pHp scripts run
> consistently. When I press refresh, sometimes a directory will exist and
> sometimes it won't. Something is screwy. Is it the server or pHp setup?[/color]

Might be server. Is it a production environment or dev?

--
<?php echo 'Just another PHP saint'; ?>
Email: rrjanbiah-at-Y!com Blog: http://rajeshanbiah.blogspot.com/
TreeNet Admin
Guest
 
Posts: n/a
#6: Jul 17 '05

re: Phantom Session Variables


In article <6d3sd.9182$_3.107336@typhoon.sonic.net>,
ben@pyramidlabel.com says...[color=blue]
> Turns out it's not just the session variables. No pHp scripts run
> consistently. When I press refresh, sometimes a directory will exist and
> sometimes it won't. Something is screwy. Is it the server or pHp setup?
>
>[color=green]
> > Hello,
> >
> > My $_SESSION variables disappear and reappear. It's not just
> > a matter of not caching the page. I usually have to press the Refresh
> > button about 3 times to get the page to remember the variables. Sometimes
> > refreshing again will cause the variables to disappear again. PHPSESSID
> > will often be empty after using session_start().
> > Any ideas on how to limit this action?
> >
> > Thanks, Ben[/color]
>[/color]

I had similar access problems once.
Check the PHP GroupID and UserID security check settings in php.ini.

Turn them off and test the scripts.

Not failing? Check the PHP user/group has _ownership_ and read/write of
the session directory.

If PHP doesn't have security access to read or write a directory it can
sometimes fail quietly. @include hides errors and 'critial only' error
reporting also can hide fatal problems.

--
AJ
Treehouse Networks abuse@
www.treenetnz.com
Closed Thread