You are here: Re: rowspan/colspan help « HTML « IT news, forums, messages
Re: rowspan/colspan help

Posted by Jukka K. Korpela on 01/27/07 13:38

Scripsit TheBagbournes:

> I figured it out :

I don't think so. You didn't react the question whether you should really
use a table, and this normally means you shouldn't.

Moreover, you seem to have rejected my simple and correct markup in favor of
more complex and less correct.

> <table cellspacing="0" cellpadding="0">
> <tr>
> <td rowspan="2">
> Single Row
> </td>
> <td>
> Top half
> <td>
> </tr>
> <tr>
> <td colspan="2">
> Bottom half
> </td>
> <tr>
> </table>
>
> You have to give the td on the second row colspan="2",

Wrong.

> otherwise the
> table is not balanced (every row has to have the same number of
> columns spanned).

Wrong. _Your_ table is not balanced, since the first row has two columns and
the second row has three columns: one cell shared with the upper row and two
columns spanned by the second cell.

Did you look at the effect? Add border="1" to the <table> tag and you'll see
that your table is not balanced: "Top half" is a bit narrower than the
"Bottom half", because there is ghost column, so to say.

An unbalanced table is not explicitly forbidden in HTML specifications, but
the effects are unpredictable.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация