Sometimes it’s nice to break free of classes and objects and just use arrays to manage your data. toArray() returns an associative array with the values from your row object.



require_once('config.php');

//Load Book with Primary Key(ID) of 23
$b = Book::retrieveByPK(23);
//Load column values into an array
$bookArray = $b->toArray();
//Do something with the array
echo $bookArray['Title'];

?>

(503) 746-9116 | 17933 NW Evergreen Parkway, Suite 220 | Beaverton, Oregon 97006