Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Brad Rix on Feb 17, 2008 10:17
open dhtmlx forum
dhtmlgrid --> rowspan in table {header and body question}

In the v1.5 professional version, rowspan is allowed on a cell of table.

rowspan in Header Question:
What is the syntax to apply the rowspan the header rows of a table?

rowspan in Body of Table question:
If we set rowspan with <cell rowspan=2>......, how do I designate that cell does not exist in the next row?

Thank you for your assistance.
Answer posted by Support on Feb 18, 2008 06:51
>> If we set rowspan with <cell rowspan=2>......, how do I designate that cell does not exist in the next row?
Event if row included in rowspan - you still need to provide empty cell tag for second row

    <row id="1">
       <cell rowspan="2">01</cell>
       <cell>02</cell>
    </row>
    <row id="1">
       <cell></cell>
       <cell>02</cell>
    </row>


>> rowspan in Header Question:
>> What is the syntax to apply the rowspan the header rows of a table?

colspans and rowspans in header can be created by using #cspan and #rspan labels in header, the cells with such labels will be joined with related cells

    grid.setHeader("A,B,C");
    grid.attachHeader("A,#rspan,C");

will render
    |  A |    | C |
    ----  B ----
    | A |     |  C