July 2017
Intermediate to advanced
456 pages
11h 32m
English
The tableselect type creates a table with checkboxes or radio buttons to allow a user to select either single or multiple rows within a table. You need to provide the #header attribute as an associative array of columns and #options as an array of values, each containing an associative array mapping a value to the key of the #header column. In addition, you can provide the following optional attributes:
Consider this example:
$form['table'] = array( '#type' => 'tableselect', '#header' => ...
Read now
Unlock full access