strrev(md5(base64_encode('qwerty')));
<?= ListView::widget([
'dataProvider' => $dataProvider,
'itemOptions' => ['tag' => false],
//'itemView' => '_teaser',
'itemView' => function ($model, $key, $index, $widget) {
return $this->render('_teaser', [
'model' => $model,
'key' => $key,
'index' => $index,
'widget' => $widget,
]);
}
]) ?>
<div class="item" data-key="<?=$model->id?>">
...
</div>
<?php if (($index+1) % 3 == 0) : ?>
я после третьего?
<?php endif; ?>