jquerydatatablesscrollable-table

Make a scrollable content with jquery datatable


is there any way to make a scrollable content with jquery datatable??

here is my script :

oTable = $('#tablex').dataTable
    ({
        "sDom": "<'scrollContent't>T<'fg-toolbar ui-widget-header ui-corner-tl ui-corner-tr ui-helper-clearfix'lfr>t<'fg-toolbar ui-widget-header ui-corner-bl ui-corner-br ui-helper-clearfix'ip>",
        "bJQueryUI": true,
        "aoColumns": [
        null,
        null,
        { "sType": "formatted-num" },
        { "sType": "formatted-num" },
        { "sType": "formatted-num" },
        { "sType": "num-html" },
        { "sType": "num-html" }],
        "aLengthMenu": [[10, 15, -1], [10, 15, "All"]],
        "fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {
        /* Bold the grade for all 'A' grade browsers */
            var index = iDisplayIndex +1;
            $('td:eq(0)',nRow).html(index);
            return nRow;
        }
    });

when i tried it in firefox 3.6.19 it seems works fine, but when i tried it in firefox 5.0.1, it's doesn't works @.@ is there anyhing wrong with my script?? maybe anyone can help me?? thx..


Solution

  • Datatables supplies a way to set the size of the scrollable content...

    "sScrollY": "200px",
    

    http://www.datatables.net/examples/basic_init/scroll_y.html