- $col_name: Column name
- $edithidden: Boolean value indicating whether the column is editable. The default value is set to true. This only applies when the edit mode is “FORM”. A hidden column cannot be editable in “INLINE” edit mode.
- Hide a column in datagrid when displayed
- To hide column in both datagrid and form, set the second parameter to false
- Important: The data are still sent to the browser but hidden using CSS display:none. For sensitive data such as passwords and SSN etc, do not use this method, instead do not include those fields in your SQL at all.
// hide only in grid display
$dg -> set_col_hidden('employeeNumber');
// hide in both gird and edit form
$dg -> set_col_hidden('DOB', false);