如何使用jQuery使用滚动条在html中创建可调整大小的表?

sur*_*ajR 6 html jquery html-table scrollbar resizable

我想用HTML创建一个具有可调整大小的列的表.我还想要滚动条到表,但滚动时表的标题应保持固定.

请帮忙.

Mil*_*age 3

www.tablefixedheader.com

只需创建一个基本的有效 HTML,如下例所示。但请注意,层次结构必须是:

 - table > thead > tr > th
 - table > tbody > tr > td
Run Code Online (Sandbox Code Playgroud)

调整大小的列的示例

    $('#4').fixheadertable({ 
    caption     : 'My employees', 
    colratio    : [50, 150, 150, 150, 220, 150], 
    height      : 200, 
    width       : 800, 
    zebra       : true,
    resizeCol   : true,
    minColWidth : 50 
});
Run Code Online (Sandbox Code Playgroud)