LLMS_Admin_Settings::set_field_defaults( array $value = array() )
Add and set default values for a field when looping
Description Description
Parameters Parameters
- $value
-
(array) (Optional) associative array of field data
Default value: array()
Return Return
(array) associative array of field data
Source Source
File: includes/admin/class.llms.admin.settings.php
public static function set_field_defaults( $value = array() ) { if ( ! isset( $value['id'] ) ) { $value['id'] = ''; } if ( ! isset( $value['title'] ) ) { $value['title'] = isset( $value['name'] ) ? $value['name'] : ''; } if ( ! isset( $value['class'] ) ) { $value['class'] = ''; } if ( ! isset( $value['css'] ) ) { $value['css'] = ''; } if ( ! isset( $value['default'] ) ) { $value['default'] = ''; } if ( ! isset( $value['desc'] ) ) { $value['desc'] = ''; } if ( ! isset( $value['desc_tooltip'] ) ) { $value['desc_tooltip'] = false; } return $value; }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
1.4.5 | Introduced. |