Posted: Tue Aug 05, 2008 8:48 am Post subject: [MYSQL] Problem retrieving query result
Hi,
Im trying to retrieve data from a database with teh following code:
Code:
$username=mysql_real_escape_string($_POST['username']);
$password=mysql_real_escape_string($_POST['password']);
$qry="SELECT User_ID FROM users WHERE user_nick='$username' AND user_pass='".md5($password)."'";
print($qry);
$result=mysql_query($qry);
print($result);
print($qry); prints a well formed sql statement on the lines of SELECT User_ID FROM users WHERE user_nick='mewt' AND user_pass='098f6bcd4621d373cade4e832627b4f6', however print($result) does not print anything. Running the query in query browser, returns a row np...
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum