inc/auth.inc.php
changeset 192 3d18290ac993
parent 136 c795dd75a77e
--- a/inc/auth.inc.php	Thu Jul 24 17:21:33 2008 +0000
+++ b/inc/auth.inc.php	Thu Aug 07 18:45:13 2008 +0000
@@ -47,7 +47,7 @@
 	if(isset($_SESSION["userlogin"]) && isset($_SESSION["userpwd"]))
 	{
 		//Username and password are set, lets try to authenticate.
-		$result = $db->query("SELECT id, fullname FROM users WHERE username=". $db->quote($_SESSION["userlogin"])  ." AND password=". $db->quote(md5($_SESSION["userpwd"]))  ." AND active=1");
+		$result = $db->query("SELECT id, fullname FROM users WHERE username=". $db->quote($_SESSION["userlogin"], 'text')  ." AND password=". $db->quote(md5($_SESSION["userpwd"]), 'text')  ." AND active=1");
 		if($result->numRows() == 1)
 		{
 			$rowObj = $result->fetchRow();