GF_Field_SingleShipping
Source: includes/fields/class-gf-field-singleshipping.php:8
Details
- Kind:
class - Namespace:
(global) - Extends: GF_Field
Properties
| Property | Type | Description |
|---|---|---|
$duplicatable | bool | Whether there can be more than one of this field type per form. |
$repeatable | bool | Whether the field can be used in a repeater. |
$_supports_state_validation | bool | Indicates if this field supports state validation. |
Methods
| Method | Description |
|---|---|
get_form_editor_field_icon() | Returns the field's form editor icon. |
get_value_entry_detail() | Format the entry value for display on the entry detail page and for the {all_fields} merge tag. |
post_convert_field() | Actions to be performed after the field has been converted to an object. |
get_values_for_state_hash() | Prepares the value that will be hashed on form display as part of the state. |
get_value_for_state_validation() | Returns the value to use when the state is validated. |
Method Reference
get_form_editor_field_icon()
public function get_form_editor_field_icon()
Returns the field's form editor icon.
This could be an icon url or a gform-icon class.
Returns
string
Since: 2.8
Source: includes/fields/class-gf-field-singleshipping.php:48
get_value_entry_detail()
public function get_value_entry_detail( $value, $entry=[], $use_text=false, $format='html', $media='screen' )
Format the entry value for display on the entry detail page and for the {all_fields} merge tag.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$value | string | array | The field value. | |
$entry | array | [] | The entry. |
$use_text | bool | false | false | When processing choice based fields should the choice text be returned instead of the value. |
$format | string | 'html' | The format requested for the location the merge is being used. Possible values: html, text or url. |
$media | string | 'screen' | The location where the value will be displayed. Possible values: screen or email. |
Returns
string
Since:
1.92.9.29(Changed the second parameter $currency (string) to $entry (array).)
Source: includes/fields/class-gf-field-singleshipping.php:97
post_convert_field()
public function post_convert_field()
Actions to be performed after the field has been converted to an object.
Since: 2.4.8.2
Source: includes/fields/class-gf-field-singleshipping.php:120
get_values_for_state_hash()
public function get_values_for_state_hash( $value )
Prepares the value that will be hashed on form display as part of the state.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$value | string | array | The value on display. |
Returns
array
Since: 3.0
Source: includes/fields/class-gf-field-singleshipping.php:136
get_value_for_state_validation()
public function get_value_for_state_validation( $value )
Returns the value to use when the state is validated.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$value | string | array | The submitted value. |
Returns
array
Since: 3.0
Source: includes/fields/class-gf-field-singleshipping.php:153