Re: session_register()
| From: | Richard Lynch | Date: | Fri, 16 Feb 2001 00:32:20 +0000 |
| Subject: | Re: session_register() | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-40032@lists.php.net to get a copy of this message | ||
> <?
> session_start();
> session_register('email');
> $session = session_id();
> $userid = '$user';
> $sql = "SELECT *
> FROM users
> WHERE user='$user' and pass='$pass'";
> if ($num == 1) {
> include "quote2.php";
> }
Unless quote2.php sets $email, you've never set it to anything.
You've probably got their email in $result -- you just need to pull it out
and set it.
$email = mysql_result($result, 0, 'email');