Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

How can I split the column table in 3 ways?

So I need to split my column table like this
enter image description here

in the middle we got a split by rows it I can do by colspan: 1; but how can I split it by column at the same time

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

This is how you do it

table td,
table th{
  border: 1px solid #ccc;
  padding:10px
}
<table>
  <thead>
    <tr>
      <th rowspan="2">Head</th>
      <th colspan="2">Split Head </th>
      <th rowspan="2">Head</th>
    </tr>
    <tr>
      <th>asd</th>
      <th>asd</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>1</td>
      <td>2</td>
      <td>3</td>
      <td>4</td>
    </tr>
    <tr>
      <td>1</td>
      <td>2</td>
      <td>3</td>
      <td>4</td>
    </tr>
  </tbody>
</table>
Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading