Need help displaying data from a mysql query
If I search a database and it returns multiple results, what should I use to grab each result so that I can display each one in the browser. Below is the search and I thought I would use the num_rows variable to how a message if no results are found.
While the below is not quite formatted the way it will end up looking, I basically want to have a for loop go through the results and show each one in HTML similar to below. I assume that maybe an array would be best for this but I am not sure what the function is to get the results into an array.
$result = mysql_query("SELECT isbn, bookTitle, bookAuthor, thumbnail FROM BooksForSell WHERE ISBN='".$booksearch."'") or die(mysql_error());
$num_rows = mysql_num_rows($result);
Title: ' .$title. '
Author: ' . $author . '
ISBN: ' . $isbn . '
Price: ' .$price'
Condition: '. $condition . '