Topic: How to write a mysql_num_rows?

I need to know how to write this in the db class thingy X_X

$equipment = mysql_num_rows(mysql_query("select * from useritems where owner_id = '$tjeid' and location = '1'"));

Re: How to write a mysql_num_rows?

$equipment = $db->num_rows(mysql_query("select * from useritems where owner_id = '$tjeid' and location = '1'"));

Re: How to write a mysql_num_rows?

Thank you