[Wikipedia-l] What a wiki table syntax needs to do to work withcurrent table layouts
The Cunctator
cunctator at kband.com
Sat Aug 3 14:32:05 UTC 2002
A wiki markup that's simple but able to handle reasonably fancy tables by
employing stylesheets.
The complicated Sainfoin table (http://www.wikipedia.com/wiki/Sainfoin)
would be written as:
[[table:plant
[{ Sainfoin }]
[| [image: OnobrychisViciifolia-thumb.jpg] |]
[{ [[Scientific classification]] }]
[| [[table:classification
[| [[Kingdom (biology)|Kingdom]]: | [[Plantae]] |]
[| [[Division (biology)|Division]]: | [[Magnoliophyta]] |]
[| [[Class (biology)|Class]]: | [[Magnoliopsida]] |]
[| [[Order (biology)|Order]]: | [[Fabales]] |]
[| [[Family (biology)|Family]]: | [[Fabaceae]] |]
[| [[Genus]]: | '''''Onobrychis''''' |]
[| '''[[Species]]:''' | '''''vicifolia''''' |]
]]
|]
[{ [[Binomial nomenclature|Binomial name]] }]
[| ''Onobrychis vicifolia'' |]
]]
{ } is for th, | | is for td.
To explain, I'll use the reduced :
[[table:plant
[{ Sainfoin }]
[| ''Onobrychis vicifolia'' |]
]]
would be rendered as
<table class="plant">
<tr><th class="plant">Sainfoin</th></tr>
<tr><td class="plant"><em>Onobrychis vicifolia</em></td></tr>
</table>
In theory, we could write
[[table:plant]]
[{ Sainfoin }]
[| ''Onobrychis vicifolia'' |]
instead, by using a blank-line rule to determine when tables end. That looks
nicer and probably would be simpler to parse. But would be a bit less
flexible. Do we need that flexibility? Not necessarily.
More information about the Wikipedia-l
mailing list