RE: [PHP-WIN] Basic Clarification on Sessions(PHP4)

From: Date: Wed, 17 Jan 2001 23:10:33 +0000
Subject: RE: [PHP-WIN] Basic Clarification on Sessions(PHP4)
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-5080@lists.php.net to get a copy of this message
Mujahid The sample implementation is correct and works here in a Linux/Apache environment. However, I cannot get the sample to work in a Windows 2000/IIS environment. Please let us know what environment you are currently running in. Alistair -----Original Message----- From: Mujahid Wazir [mailto:mujahid@iqura.net] Sent: 17 January 2001 05:36 To: php-windows@lists.php.net Subject: [PHP-WIN] Basic Clarification on Sessions(PHP4) Hi, I want to know if the sample implementation below of session variables is correct. I am going through the PHP4 Manual, but any clarification would be great INDEX.PHP <? session_start(); $example = 1; session_register("example") ; ?> SOME OTHER PAGE <? session_start(); if (!isset($example)) { Header("Location: Index.php") ; } ?> I tried using session_is_registered() instead of isset but I am getting errors, probably because of incorrect syntax. All I want is to redirect the user back to the main page if the session is not set. Can anyone please show me the right way. Thanks -Mujahid -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net For additional commands, e-mail: php-windows-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.windows (#5080) next »