ColModifierLookupTable
extends ColModifier
in package
Returns data from a database table.
This is basically than ColModifierLookupArray(Pdb::lookup), but it doesn't call the Pdb::lookup until right before it's needed, so if the itemlist doesn't get used, we aren't wasting a db call.
Table of Contents
Properties
Methods
- __construct() : void
- ColModifierLookupTable
- modify() : string
- Modify a column value This value will be html/csv/etc encoded afterwards.
Properties
$column
private
mixed
$column
$data
private
mixed
$data
$table
private
mixed
$table
Methods
__construct()
ColModifierLookupTable
public
__construct(string $table[, string $column = 'name' ]) : void
Parameters
- $table : string
-
Table name unprefixed
- $column : string = 'name'
-
Optional column replacement for
name
modify()
Modify a column value This value will be html/csv/etc encoded afterwards.
public
modify(string $val, string $field_name, mixed $row) : string
Parameters
- $val : string
-
The incoming value
- $field_name : string
-
The name of the field being modified
- $row : mixed
-
The full row of data
Return values
string —The modified value