I have read through many other threads about this exact problem, but i for some reason can not solve my problem. Really need some help.
if (!$username||!$passwo
You can try like this
$sql= "SELECT * FROM Test WHERE username = '".$username."'";
$check = mysql_query($sql);
I think your $check returns null that is no user with this username and null can't be a parameter mysql_num_rows() function.
if($check)
{
echo "Username already taken";
}
else
{
echo "Username available";
// do other actions
}