I have a foreach loop that has data. I am using a foreach loop to echo the data out into a table.
@foreach($data as $key)
<tr>
<td></td>
</tr>
@endforeach()
This gives me a table with one column and 1 row of data. This table only has one data field and instead of one long list of data, i want it spread over 4 columns.
I would like to have 4 columns so the table looks nice and neat.
Please see attached example image.
What i am trying to achieve, after the 4 columns if there is more data then it starts the next row with 4 columns.
source https://stackoverflow.com/questions/76928967/divide-laravel-table-into-4-columns-from-a-single-foreach
No comments:
Post a Comment