Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
GrooveOnBeat Posted October 16, 2016 Posted October 16, 2016 What I want to do is display 3 columns per row. The Page code is: {{foreach $rows as $row}} {{$idField = $row::$databaseColumnId;}} ...content... {{endforeach}} I've tried to do a template logic like below but failed: {{if $row % 3 == 2}} line break {{endif}} {{if $row == 3}} line break {{endif}} How do I do it?
GrooveOnBeat Posted October 16, 2016 Author Posted October 16, 2016 Didn't work either... {{if $row % 3 == 0}} line break {{endif}} or {{if count($rows)}} {{foreach $rows as $id}} {{if $id % 3 == 0}} line break {{endif}} {{endforeach}} {{endif}}
GrooveOnBeat Posted October 23, 2016 Author Posted October 23, 2016 I've been trying different things but not getting the results. Any ideas?
Meddysong Posted October 23, 2016 Posted October 23, 2016 You'd need to use the ipsGrid class, I think. Something like: <div class="ipsGrid"> {{foreach $rows as $row}} {{$idField = $row::$databaseColumnId;}} <div class="ipsGrid_span4"> ... stuff </div> {{endforeach}} </div>
GrooveOnBeat Posted October 24, 2016 Author Posted October 24, 2016 18 hours ago, Meddysong said: You'd need to use the ipsGrid class, I think. Something like: <div class="ipsGrid"> {{foreach $rows as $row}} {{$idField = $row::$databaseColumnId;}} <div class="ipsGrid_span4"> ... stuff </div> {{endforeach}} </div> As specified in the layout.css, I didn't think about using that. Thanks! With this I can customize or even redo the classes to customize the width, margin, and padding. Thank you!
Recommended Posts
Archived
This topic is now archived and is closed to further replies.