Display Database Records as items, not as grid

Hello,

I looked into many tutorials and books but all work with the standard Gridview of the CRUD Generator :(

How can i accomplish that the Records are displayed in an own style?

The goal is to have an image with text underneath, like the most Online-Shops have it for every Record.

So the best way i think is to define a itemtemplate and for every record the template is filled with the record data?

Hi!

Very small and short example:




use app\models\User;


// find all active users

$users = User::findAll(['status' => '10']);


foreach($users as $user){

    echo $user->username."<br>";

}




But of course you have multiple options.

Of course you can also create an item-view and use it in the Grid/Listview Widget.

Regards