Member Avatar for feoperro

Hi,

Simple question:

How do you make a table with 2 columns?

On the left column - 1 row
On the right column - 2 rows

-Without using a nested table.

Thanks,
Ashton.

You can use rowspan.

<table>
  <tr>
    <td rowspan="2">1</td>
  </tr>
  <tr>
    <td>2</td>
    <td>3</td>
  </tr>
</table>
Member Avatar for feoperro

Thanks Bender ;)

You can use rowspan.

<table>
  <tr>
    <td rowspan="2">1</td>
  </tr>
  <tr>
    <td>2</td>
    <td>3</td>
  </tr>
</table>

You would need colspan for that, not rowspan. You would use rowspan like this:

<table>
  <tr>
    <td rowspan="2">1</td>
    <td>2</td>
  </tr>
  <tr>
    <td>3</td>
  </tr>
</table>
Member Avatar for feoperro

Ya you're right

Crap... totally missed it. (That is what I meant though.) Must be the booze.

Member Avatar for feoperro

Hahaha!

Wow I hope this isnt for a page layout...lol

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.