Brimbox Logo Brimbox Version 2.3.4 Released

column_dropdown>>

Outputs a HTML dropdown object containing the different Brimbox columns available for a given layout. This method is usually used within the Brimbox required form.

Class: bb_main, called as $main

File: bb_main.php (php)

Declaration:

function column_dropdown($arr_columns, $name, $col_type, $params = array())

Usage:

$main->column_dropdown($arr_columns, $name, $col_type, $params);

Outputs: Dropdown menu of available columns, the key to the dropdown will be col_type.

Note: There is a security option $check in the optional $params array.

Parameter: $arr_columns (array)
Full or reduced column definitions for a given layout from the json_table, $arr_columns should be reduced by $row_type and stripped of associative keys. The value of the dropdown is the integer col_type which corresponds to the array key and columns in the data_table (ie 1 => c01, 2 => c02).

Parameter: $name (string)
Name of the HTML select object, usually called col_type since it corresponds to the columns fields in the data_table.

Parameter: $col_type (integer)
The integer value currently populated in the dropdown, usually from the interface state or a postback. Causes the select tag to be selected for $col_type specified.

Parameter: $params (optional array)
The parameters array for passing custom parameters to the function. Parameters not reserved will be outputted as HTML attributes.

Reserved Parameters:

  • all, whether to include “All” value with col_type of 0 (boolean)
  • empty, default false, true will set an empty value of -1 (0 reserved for all) (boolean)
  • check, security check, displays all levels below check, default is 0 which displays all columns. (integer)

 

Updated: 2016-07-17