Align the vertical position of the first div in multiple header cells
P粉322106755
P粉322106755 2023-09-06 10:15:16
0
1
554

I have an element that contains multiple divs, multiple divs inside the first header cell and only one div inside the second header cell. If you run the code below, "123" will appear centered (vertically aligned with "abc") -

<table style="width:100%">
  <tr>
    <th>
      <div>abc</div>
      <div>xyz</div>
    </th>
    <th>
      <div>123</div>
    </th>
  </tr>
</table>

I want to align 'abc' and '123' vertically.

P粉322106755
P粉322106755

reply all(1)
P粉191610580

Change the vertical alignment of cells with "123"

<table style="width:100%">
  <tr>
    <th>
      <div>abc</div>
      <div>xyz</div>
    </th>
    <th style="vertical-align: top;">
      <div>123</div>
    </th>
  </tr>
</table>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template