Re: Session in Windows 2000
| From: | zhming | Date: | Fri, 11 Apr 2003 07:19:07 +0000 |
| Subject: | Re: Session in Windows 2000 | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-19383@lists.php.net to get a copy of this message | ||
he he
is right
"Danilo Meles" <dmeles@paraisonet.com.br> wrote in message
news:001201cd7c16$5599cd00$23cecac8@BLUE...
> Hi Folk's
>
> I'm having some problems using session on PHP.
>
> PHP is installed under Windows 2000 IIS (INtenet Information server)
>
> I Create a session using the code above:
> session_start();
> session_name("teste");
> $session_login = "$login";
> session_register("session_login");
>
> And the session is saved in the correct folder I put in php.ini.
>
> The problem is at the time the user click to logoff this application,
I've
> used:
>
> session_start("teste");
> if ( !session_destroy("teste") ) {
> echo "User conected!!!";
> }
> else {
> echo "User not conected $temp !!!";
> }
>
> When it ocurrs , user will not be able to access any template on the site
> because the session must exist. Something like this:
> session_start("teste");
>
> if (session_is_registered("session_login")) {
> echo "Clique para desconectar: ";
> echo "<a href=\"desconectar.php\">Desconectar</a>";
>
> }
> else {
> header("Location: index.php");
> }
>
> The problem is when the session is destroyed , nothing happens. The
session
> was not destroyed. But if we run the same application on linux it works
> very good !!!
>
> Could you help me, please???
>
> Thank you a lot!!
>
> Danilo Meles
>