![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
|
On 23 Feb, 08:11, Ian Rastall <rastall... (AT) gmail (DOT) com> wrote: I've been reading a book called "Everything You Know About CSS Is Wrong." If you use grid markup, you need some tags to do it with. HTML doesn't have many options here, apart from <table> and children, so you're probably pushed into using an anonymous <div> and classes upon it. Given the choice, <div class="tr"> has little to offer over <tr> for coding style. Yes, there's some neat concise markup you can do with dl> that's rendered into tables too, but this isn't earth-shattering. |
#2
| |||
| |||
|
|
On 23 Feb, 12:01, Andy Dingley <ding... (AT) codesmiths (DOT) com> wrote: On 23 Feb, 08:11, Ian Rastall <rastall... (AT) gmail (DOT) com> wrote: I've been reading a book called "Everything You Know About CSS Is Wrong." If you use grid markup, you need some tags to do it with. HTML doesn't have many options here, apart from <table> and children, so you're probably pushed into using an anonymous <div> and classes upon it. Given the choice, <div class="tr"> has little to offer over <tr> for coding style. Yes, there's some neat concise markup you can do with dl> that's rendered into tables too, but this isn't earth-shattering. Is this right? I've just been trying to code up a neat little example of this table-like <dl> styling, which unfortunately this margin is too small to contain. This CSS: dl dt, dl dd { display: table-cell; } Generates a single-row table for an arbitrary list of elements, rendering each as a table cell. The CSS is (AIUI) correct despite not using display: table; or display: table-row; because there's an implication behaviour in the CSS specification that will insert an anonymous one, if needed. The almost equally simple CSS: dl dt { display: table-row; } dl dd { display: table-cell; } Generates a multi-row presentation instead, where each <dt> starts a new row. However, there doesn't seem to be any way (and I mean "any way", not just "an easy way") to transform dt ... /><dd ... /><dt ... /><dd ... / into an "obvious" two-dimensional, two-row, two-column layout. Is there one? Even generated content seems incapable of assisting. In the general sense, it seems that "CSS tables" are not only _unnecessary_ for HTML+CSS (for thier justification with XML+CSS see "XML and Tables" in Lie & Bos), but it's actually impractical to use them with any valid HTML markup other than <table> etc. or anonymous div> labelled by classes. The problem is that adequate markup of the content language for a table structure requires around four levels of structure (akin to <table>, <tbody>, <tr> & <td>) and it's only possible to reduce this to two (<tr> & <td>) by implication. It is _not_ possible to take HTML's general <dl> elements and use them to adequately mark up a useful table with multiple rows. HTML+CSS tables (outside <table>) aren't just unnecessary, they're unworkable. Discuss. If you think classes have no value, then you're right. A table by nature |
#3
| |||
| |||
|
|
It would have made good sense, even before CSS came into the picture, for definition lists to have been conceived of as three-level structures: list, entry, terms/definitions. |
#4
| |||
| |||
|
|
On 23 Feb, 12:01, Andy Dingley <ding... (AT) codesmiths (DOT) com> wrote: On 23 Feb, 08:11, Ian Rastall <rastall... (AT) gmail (DOT) com> wrote: I've been reading a book called "Everything You Know About CSS Is Wrong." If you use grid markup, you need some tags to do it with. HTML doesn't have many options here, apart from <table> and children, so you're probably pushed into using an anonymous <div> and classes upon it. Given the choice, <div class="tr"> has little to offer over <tr> for coding style. Yes, there's some neat concise markup you can do with dl> that's rendered into tables too, but this isn't earth-shattering. Is this right? I've just been trying to code up a neat little example of this table-like <dl> styling, which unfortunately this margin is too small to contain. This CSS: dl dt, dl dd { display: table-cell; } Generates a single-row table for an arbitrary list of elements, rendering each as a table cell. The CSS is (AIUI) correct despite not using display: table; or display: table-row; because there's an implication behaviour in the CSS specification that will insert an anonymous one, if needed. |
|
The almost equally simple CSS: dl dt { display: table-row; } dl dd { display: table-cell; } Generates a multi-row presentation instead, where each <dt> starts a new row. However, there doesn't seem to be any way (and I mean "any way", not just "an easy way") to transform dt ... /><dd ... /><dt ... /><dd ... / into an "obvious" two-dimensional, two-row, two-column layout. Is there one? |
|
Even generated content seems incapable of assisting. |
#5
| |||
| |||
|
|
In article <70g907F525t7U1 (AT) mid (DOT) individual.net>, Harlan Messinger <hmessinger.removethis (AT) comcast (DOT) net> wrote: It would have made good sense, even before CSS came into the picture, for definition lists to have been conceived of as three-level structures: list, entry, terms/definitions. Things make sense if you can afford them. If you have a lot of money, it makes sense to pay for a view to go with a house purchase. If you can afford a complication in system, it makes sense to have lots of html elements with specialised functions. But simplicity has its own rewards. HTML lists generally are an indulgence, tables always being available to do a perfectly capable job. |
#6
| |||
| |||
|
|
dorayme wrote: .... HTML lists generally are an indulgence, tables always being available to do a perfectly capable job. Lists make a lot of sense for navigation. Easy to style and set background images. Easy to change from vertical to horizontal layout. .... |
![]() |
| Thread Tools | |
| Display Modes | |
| |