Multiple rows in td

后端 未结 1 957
误落风尘
误落风尘 2021-01-22 20:54

Stores contain table with mulitple rows. A store can have mulitple stores (rows).

See Example: https://jsfiddle.net/ak3wtkak/1/

The wi

相关标签:
1条回答
  • 2021-01-22 21:42

    You have to use rowspan. Make the first 2 rows with rowspan of 3.

    <table border="1" width="100%">
      <thead>
        <tr>
          <th style="width:300px">Product</th>
          <th>Barcode</th>
          <th>Stores</th>
          <th class="middle">Quantity</th>
        </tr>
      </thead>
    
      <tbody>
        <tr>
          <td rowspan="3">Item 1</td>
          <td rowspan="3">12345</td>
          <td>Store Name 1</td>
          <td>4</td>
        </tr>
        <tr>
          <td>Store Name 2</td>
          <td>4</td>
        </tr>
        <tr>
          <td>Store Name 3</td>
          <td>4</td>
        </tr>
      </tbody>
    </table>
    
    0 讨论(0)
提交回复
热议问题