MarkupAdminDataTable class

Generates markup for data tables used by ProcessWire admin

Click any linked item for full usage details and examples. Hookable methods are indicated with the icon. In addition to those shown below, the MarkupAdminDataTable class also inherits all the methods and properties of: ModuleJS, WireData and Wire.

Show class?             Show args?        

Common

NameReturnSummary 
action(array $action)
$thisAdd action(s) button underneath the table 
actions array 
addClass(string $class)
(nothing)Add a class to the table (without replacing existing ones) 
caption string 
class string 
encodeEntities bool 
footerRow(array $a)
$thisSet the footer row for the table
Can also be used as property: footerRow
 
get(string $key)
mixed nullGet property 
headerRow(array $a)
$thisSet the header row for the table
Can also be used as property: headerRow
 
id string 
isAutoload()
(nothing) 
isSingular()
(nothing) 
removeClass(string $class)
(nothing)Remove a class from the table 
render()
stringRender the table
resizable bool 
responsive bool 
row(array $a)
$thisAdd a row to the table 
rowAttrs array 
rowClasses array 
rows array 
setCaption(string $caption)
(nothing)Set table caption 
setClass(string $class)
(nothing)Set class(es) to add to table 
setColNotSortable(int $index)
(nothing)Set a column as not sortable (first column is 0) 
setEncodeEntities()
(nothing)Set whether or not entity encoding is enabled 
setID(string $id)
(nothing)Set table id attribute 
setResizable(bool $resizable)
(nothing)Set whether or not table is resizable 
setResponsive()
(nothing)Set the responsive mode of this table 
setSortable(bool $sortable)
(nothing)Set whether or not table is sortable 
settings(string $key)
string int array null MarkupAdminDataTableGet or set an internal setting
Can also be used as property: settings
 
sortable bool 

Additional methods and properties

In addition to the methods and properties above, MarkupAdminDataTable also inherits the methods and properties of these classes:

API reference based on ProcessWire core version 3.0.244

“ProcessWire is like a breath of fresh air. So powerful yet simple to build with and customise, and web editors love it too.” —Margaret Chatwin, Web developer