Answers for "laravel loop through collection and take out values from each item"

PHP
3

laravel loop through collection

$users = AppUser::where('active', 1)->get();

foreach ($users as $user) {
    echo $user->name;
}
Posted by: Guest on March-17-2020

Code answers related to "laravel loop through collection and take out values from each item"

Browse Popular Code Answers by Language