![Picture of Gerry Danen Picture of Gerry Danen](/graphics/unknown.gif)
Gerry Danen - 2016-03-29 20:19:58
I am using this method to convert objects from the execute method to arrays.
It may enhance the dbase class.
private(or public) function _objectToArray($objectIn)
{
$arrayOut = array();
if ( $objectIn )
{
foreach ( $objectIn AS $key => $item )
{
if ( is_array($item) OR is_object($item) )
{
$arrayOut[$key] = $this->_objectToArray($item);
}
else
{
$arrayOut[$key] = $item;
}
}
}
return $arrayOut;
}