Options
=====
String selector of DOM element in which table will be rendered. (in jQuery style)
Type: string
Default: null
Example: #some_table_id
=====
Array with table data structure for table header. Each element of this array is an object with structure:
{
title: "Your column title",
type: "string", // available values - 'string', 'number'
key: "key_value" // only for AJAX per page driven table. This value will be sent via AJAX request as a sort column value.
}
Detailed documentation : Table titles
Type: array
Default: []
=====
Table data array. Each data array element is an array for table row. Each table row array element is a value for table cel.
Type: array
Default: []
=====
Responds for displaying row numbers or not.
Type: boolean
Default: false
=====
Selector of DOM element in which pager will be rendered. (in jQuery style)
Type: boolean
Default: false
Example: #some_table_id_pager
=====
Defines the table start page or page that should be rendered.
Type: number
Default: 1
=====
Tell the script should it render table pagination or not.
Type: boolean
Default: true
=====
Defines the table page size (how many rows will be displayed on the table page)
Type: number
Default: 10
=====
Should script show page size selector or not.
Type: array
or boolean
Default: []
-
false
- page size selector wouldn't be displayed; -
true
- page size selector will be displayed in pager container with default page sizes; -
[5, 7, ...]
- page size selector will be displayed with select options that defined in this property
=====
Responsible for displaying navigation arrows.
Type: boolean
Default: true
=====
Responsible for displaying goto field.
Type: boolean
Default: true
=====
Defines column sorting.
Type: array
or boolean
Default: true
-
true
- enable sorting; -
false
- disable sorting; -
[1, 3, 4 ... ]
- enable sorting for defined columns;
=====
Set the default column for data sorting.
Type: number
Default: 0
=====
Defines column sort type. Available values: asc
, desc
Type: string
Default: asc
=====
Defined column prefixes. Objects key should be column number in human readable format (starts from 1).
Type: object
Default: {}
Example:
{
"2": '$ ', // 2nd table column values will be displayed with '$ ' prefix
"3": "+" // 3rd table column values will be displayed with '+' prefix
}
=====
Defined column suffixes. Objects key should be column number in human readable format (starts from 1).
Type: object
Default: {}
Example:
{
"2": '%' // 2nd table column values will be displayed with '%' suffix
}
=====
Object with functions for formatting table column data. Its properties should be column ids, and values - formatter function with value argument.
Type: object
Default: {}
Example:
{
formatter: {
"3": function( value ) {
return value == 'work' || value == 'opensource' ? '<b>' + value + '</b>' : value;
}
}
}
=====
Defines will table columns be highlighted on mouse over or not.
Type: array
or boolean
Default: false
-
false
- no column highlighting; -
true
- column highlighting for all columns except row numbers; -
[1, 2]
- column highlighting only for defined columns;
=====
Defines what columns will be hidden in table. You also should specify titles for hidden columns.
Type: array
Default: []
=====
Defines DOM element for search input element. (in jQuery format)
Type: string
Default: null
Example: #some_table_id_search
=====
Search functionality disabled or enabled.
Type: boolean
Default: false
=====
Search will reacts on each changing of search query immediately. If false - search will be only on enter key press or lost focus from the search field.
Type: boolean
Default: true
=====
Turn on/off search case sensitive mode.
Type: boolean
Default: false
=====
Defines default search value.
Type: string
Default: ``
=====
Special functionality for ajax driven tables. Detailed info you can find here - AJAX driven tables
Type: object
Default: null