@if(count($banners) <= 3) @for($i = 0; $i < count($banners); $i++)
...
@endfor @else @for($i = 0; $i < 3; $i++)
...
@endfor @endif
@if(count($banners) <= 3)
@for($i = 0; $i < count($banners); $i++)
...
@endfor
@elseif(count($banners) > 3 && count($banners) <= 6)
@for($i = 3; $i < count($banners); $i++)
...
@endfor
@elseif(count($banners) > 6) @for($i = 3; $i < count($banners); $i++) @if($i % 3 == 0)
@if(count($banners) - $i >= 3) @for($j = $i; $j <= $i + 2 ; $j++)
...
@endfor @else @for($j = $i; $j < $i + count($banners) - $i ; $j++)
...
@endfor @endif
@endif @endfor @endif
Previous Next