ColModifierJsonArray
extends UnescapedColModifier
in package
Helper for rendering out array data from a json stored string
Does not HTML encode if preformatting.
Table of Contents
Properties
- $_preformat : mixed
Methods
- __construct() : mixed
- modify() : string
- Modify a column value This value will be html/csv/etc encoded afterwards.
- implodeArrayVals() : string
- Do something readable with data that is an array
Properties
$_preformat
private
mixed
$_preformat
Methods
__construct()
public
__construct([bool $preformat = true ]) : mixed
Parameters
- $preformat : bool = true
-
Whether to wrap the content in a
tag. Will escape otherwise
modify()
Modify a column value This value will be html/csv/etc encoded afterwards.
public
modify(mixed $val, string $field_name, mixed $row) : string
Parameters
- $val : mixed
-
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
implodeArrayVals()
Do something readable with data that is an array
private
implodeArrayVals(array<string|int, mixed> $val, int $depth) : string
Parameters
- $val : array<string|int, mixed>
- $depth : int