Using "display: table-cell" is there a way of getting the "colspan" functionality? [duplicate]
Using display: table-cell
is there a way of getting the colspan
functionality, which is available when using real table cells?
In particular I need some "cells" to span multiple columns.
Real tables are not a possibility as I am using a form per row layout, which won't validate as a real table.
Solution 1:
No you cannot add colspan or rowspan to display:table-cell. It is one of the limitations in table-cell feature!
You can check the limitations in this reference link
http://www.onenaught.com/posts/201/use-css-displaytable-for-layout
If you want to bring the COLSPAN feature into table-cell, then you have to use table-row-group and table-caption feature as follows
display: table-caption
and
table-row-group;
Check this fiddle link : http://jsfiddle.net/ZQQY4/