$result didn't work as it should
Posted: Thu Sep 09, 2004 8:44 pm
I updated my verify my password using the following
?>
$query = "update user set Password = password('$new_password') where username = '$username'";
$result = @mysql_query($query);
?>
$query = "update user set Password = password('$new_password') where username = '$username'";
$result = @mysql_query($query);
Code: Select all
<?php
when injecting a invalid username, the $results still prints '1' (It should print '0' ), however mysql_affected_rows function returns '0' rows. can someone advise why is this the case.