Html code to show the data

mail@pastecode.io avatar
unknown
html
2 years ago
419 B
2
Indexable
Never
<style>
  table, th, td {
    border: 1px solid black;
  }
</style>

<table>
  <thead>
  <tr>
    <th></th>
    @foreach($months as $month)
      <th>{{ $month }}</th>
    @endforeach
  </tr>
  </thead>
  <tbody>
  @foreach($items as $item)
    <tr>
      <td>{{ $item['year'] }}</td>
      @foreach($item['months'] as $value)
        <td>{{ $value }}</td>
      @endforeach
    </tr>
  @endforeach
  </tbody>
</table>