$iterator = new LimitIterator($result);
foreach ($iterator as $row)
{
foreach ($row as $field => $value)
{
echo "$field: $value<br/>";
}
echo '<br/>';
}
Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.
Have a better answer? Share it in a comment.
From novice to tech pro — start learning today.
The whole idea of an iterator is to work your way through an entire collection. There is an iterator to array function, but since you are starting with an array that just seems pointless.
http://uk2.php.net/manual/en/function.iterator-to-array.php