What is the best PHP Database Class? (eg. PDO, PEAR, etc.)?

  • Thread starter Thread starter beyondthegrave
  • Start date Start date
B

beyondthegrave

Guest
I need a MySQL Database class that is easy to use for simple uses. All I really need is to get data, and ideally it would be similar to Joomla 1.5's Database API. For example:

$db->setQuery("SELECT * FROM `customer`");
$customerlist = $db->loadObjectList(); // Stores results in array
foreach($customerlist as $customer)
{
echo "Name: ".$customers->name;
}

That's the kind of syntax I'm used to, with the results of a SELECT stored as variables in an object, as opposed to an associative array like $customer['name'].

Any ideas?

Thanks for any help you can offer.
 
Back
Top