[html5] Table Nesting

Brian Tremblay webmaster at tsmchughs.com
Sun Apr 15 11:44:02 PDT 2012


On 4/15/12 7:27 AM, Laurence Gillian wrote:
>
> The scenario is pulling data from a fairly complex XML document,
> where the data is nested.
 >
> Node
> -- Node
> -- Node
> -- Node
> -- Node
>
> Which in the real world is;
>
> Security Team A (a:allowed cups of tea = 18, b:cups of tea drunk = 14)
> -- Joe (8,2)
> -- Bob (8,8)
> -- John (2,4)
>
> I can't see how to represent this relationship using the table
> specification?

I must be missing something. It seems quite straightforward to me:

<table>
  <thead>
   <tr>
    <th>name</th><th>allowed cups</th><th>cups drunk</th>
   </tr>
  </thead>
  <tbody>
   <tr>
    <th>Joe</th><td>8</td><td>2</td>
   </tr>
   <tr>
    <th>Bob</th><td>8</td><td>8</td>
   </tr>
   <tr>
    <th>John</th><td>2</td><td>4</td>
   </tr>
  </tbody>
</table>


> It's not possible to nest a tbody, inside a tbody, or say to use
> section/article tags to group the content

No, but why would you want to? I think you need to explain the problem a 
bit more. Is the problem with the markup? Or with traversing the xml dom 
of the data?

-- 
Brian Tremblay



More information about the Help mailing list