Formats values for an export.
Description
See also
Parameters
- $values
-
(array) (Required) Associative array of
$field => $value
pairs, with the main element field having the key '_main'. - $element
-
(awsmug\Torro_Forms\DB_Objects\Elements\Element) (Required) Element the values belong to.
- $export_format
-
(string) (Required) Export format identifier. May be 'xls', 'csv', 'json', 'xml' or 'html'.
Return
(array) Associative array of <code>$column_slug => $column_value</code> pairs. The number of items and the column slugs must match those returned from the get_export_columns() method.
Source
File: src/db-objects/elements/element-types/non-input-element-type-trait.php
public function format_values_for_export( $values, $element, $export_format ) { return array(); }
Changelog
Version | Description |
---|---|
1.0.0 | Introduced. |