acf_field_number::format_value_for_rest
Apply basic formatting to prepare the value for default REST output.
Method of the class: acf_field_number{}
No Hooks.
Returns
Mixed.
Usage
$acf_field_number = new acf_field_number(); $acf_field_number->format_value_for_rest( $value, $post_id, $field );
- $value(mixed) (required)
- .
- $post_id(string|int) (required)
- .
- $field(array) (required)
- .
acf_field_number::format_value_for_rest() acf field number::format value for rest code ACF 6.0.4
public function format_value_for_rest( $value, $post_id, array $field ) {
return acf_format_numerics( $value );
}