Proper OOP Syntax

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Given the following code:

$password = (strlen($this->user_pw) < 32) ? md5($this->user_pw) : $this->user_pw; $sql = sprintf("SELECT COUNT(*) AS test, TeamID FROM %s WHERE BINARY login = '%s' AND pw = '%s' AND active = 'y'", $this- >table_name, $this->user, $password);
		}
		$result = mysql_query($sql) or die(mysql_error());
		if (mysql_result($result, 0, "test") == 1) {
			return true;
		} else {
			return false;
		}

How would I set a session variable for the value of TeamID?

Thanks.

Albert Padley

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux