Re: session problems
| From: | Jeff Warrington | Date: | Thu, 29 Mar 2001 03:42:55 +0000 |
| Subject: | Re: session problems | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-45997@lists.php.net to get a copy of this message | ||
In article <99u746$gra$1@toye.p.sourceforge.net>, "Jeff Warrington"
<jaydub@bossanova.com> wrote:
Never mind everybody. It turns out that I had to set the
odbc_longreadline setting to make sure that the full serialized
session data was read from the DB.
Jeff
> hello all. I am attempting to register two session variables that are in
> fact class instances. As per instructions, the definitions for these
> classes are prepended to the files being loaded so the class defs are
> present when the session starts.
> If I do this on the first page:
>
> session_start();
> session_register("off");
> session_register("req");
> where "off" and "req" are actually class instances and then try this on
> page two:
>
> header("Content-Type: text/plain");
> (session_is_registered("req")) ? print("req: yes\n") : print("req:
> no\n"); (session_is_registered("off")) ? print("off: yes\n") :
> print("off: no\n"); var_dump($req);
> var_dump($off);
> I get a response that both $off and $req are registered variables.
> however the output of var_dump for $req is null while the output for
> $off shows the frozen object. If I reverse the order of the
> session_register on page one, then the var_dump shows values for $req
> but not $off.
> I am using DB storage for the sessions. my callback functions are
> operating - I can see the serialized data in the table for both the $req
> and the $off class instances.
> Any clues on where I need to look to solve this one? thanks,
> Jeff
> Running Apache 1.3.17 w/ PHP4.0.4pl1
> './configure' '--with-apache=../apache_1.3.17'
> '--enable-track-vars'
> '--with-xml' '--with-dom'
> '--with-ibm-db2=/usr/IBMdb2/V6.1/'
> '--with-zlib' '--with-curl'
> '--with-pspell' '--with-mcrypt'
> '--with-sablot'
> '--enable-sablot-errors-descriptive'
> '--enable-inline-optimization'
> '--enable-trans-sid'
> '--with-config-file-path=/opt/gr/oas/lib/' session data in php.ini is:
> [Session]
> session.save_handler = user
> session.save_path = SESSION
> session.use_cookies = 1
> session.name = XXXXXX (removed) session.auto_start =
> 0
> session.cookie_lifetime = 0
> session.cookie_path = /
> session.cookie_domain = .xxx.com (removed) session.serialize_handler
> = php
> session.gc_probability = 1
> session.gc_maxlifetime = 600
>