- Code: Select all
$query = 'select some_field from some_table where some_field = some_value';
$result = mysql_query($query);
$record = mysql_fetch_array($result);
the last line will get one record from the database each time it is called and places that in an array.
you can use a loop to walk through all records like this:
- Code: Select all
while ($record = mysql_fetch_array($result))
{
do_stuff_with_;
}
Greetz Daan

