flatbase
flatbase copied to clipboard
How to use a Flatbase\Collection ?
Complete noob, how do you iterate through all records from a Flatbase\Collection you've got with a query like this one?
$userthingies = $flatbase->read()->in("thingies")
->where("author", "=", $_SESSION["user"])
->get();
@adamnicholson @carlwhittick
I have figured it out, thanks to this thing.
foreach ($userthingies as $key => $thingie) {
echo "<li>{$thingie["name"]} <small>{$thingie["description"]}</small> by {$thingie["author"]}</li>";
}
I think the docs could be improved about this tho.