Re: Session's is slowing the page ??
| From: | Dima Dubin | Date: | Tue, 28 May 2002 10:27:45 +0000 |
| Subject: | Re: Session's is slowing the page ?? | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-99455@lists.php.net to get a copy of this message | ||
Hello Tom
I looked in the manual for session_readonly because its basicly what I need
: 1 login page, and the just read the session data in other pages....
but, there is no examples or anything like that in the manual could you
please show me a little example how to use it on my pages ?
THANKS !!
Dima.
"Tom Mikulecky" <tm@caldera.fr> wrote in message
news:3CF32F31.6F3895B6@caldera.fr...
> Hi
>
> PHP's sessions are blocking, i.e. until a session is closed, all other
calls to
> session_start() are pending. If you don't close a session explicitely, it
> remains opened until the script is terminated.
> The solution is to close a session as soon as possible
(session_write_close) or
> use non-blocking read-only sessions (session_readonly instead of
session_start)
> in case you don't need to modify registered variables.
>
> Tom
>
>
> Dima Dubin wrote:
>
> > Hello,
> > I have very wierd problem :
> > I use session to manage users and I have this structure of the page :
> > -----
> > include("db.php");
> > include("header.php");
> > bla bla
> > include("footer.php");
> > -----
> >
> > in the db.php I have :
> >
> > ----
> > session_start();
> > #some mysql connect stuff
> > ----
> >
> > I use session with the $_SESSION array (cheking if
registered[isset($_S...)]
> > and registering...)
> > and all work fine....
> > but sometimes the page loading is very very very slow (and its a really
> > really fast host) and when I removing session_start(); from the top of
the
> > page, the page load normaly.
> >
> > the PHP version is 4.1.1, someone have an idea ?
> > thanks in advance,
> > Dima.
>