List, Some time ago sortable tables was discussed. One method was found at the following site. http://www.kryogenix.org/code/browser/sorttable/ While it works, it does not allow for multiple rows of headers. It breaks if more than one row of headers is included in the html code and the author stated it would require changing the javascript code to do so. Has anyone tried modifying the script to allow at least two rows of headers? The reason a second row of headers is needed is for clarification of table content. For example, a census index might have ten columns of data. That would be one row of headers. But, to make it easier to see groups of data, another row of headers can be placed before it grouping name and location content for example. See the example that follows. householder address birth first last city county state year month date Lorrie
On Tuesday, March 08, 2011 7:15 AM (UTC+13) Lorries wrote:- > Some time ago sortable tables was discussed. One method was found at the > following site. > > http://www.kryogenix.org/code/browser/sorttable/ > > While it works, it does not allow for multiple rows of headers. It > breaks if more than one row of headers is included in the html code and > the author stated it would require changing the javascript code to do so. > > Has anyone tried modifying the script to allow at least two rows of > headers? The reason a second row of headers is needed is for > clarification of table content. For example, a census index might have > ten columns of data. That would be one row of headers. But, to make it > easier to see groups of data, another row of headers can be placed > before it grouping name and location content for example. See the > example that follows. > > householder address birth > first last city county state year month date -------------------------- Lorrie, <table><tr> <th colspan="2"></th><th colspan="3"></th>><th colspan="3"></th> </tr><tr> <td colspan="8"> <table id="sortable"><tr> <th></th><th></th><th></th><th></th><th></th><th></th><th></th><th></th> </tr><tr> <td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td> </tr><tr> <td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td> </tr></table> </td></tr></table> That should meet your requirements. Barry