acf_field_post_object::render_field_validation_settings
Renders the field settings used in the "Validation" tab.
Method of the class: acf_field_post_object{}
No Hooks.
Returns
null. Nothing (null).
Usage
$acf_field_post_object = new acf_field_post_object(); $acf_field_post_object->render_field_validation_settings( $field );
- $field(array) (required)
- The field settings array.
Changelog
| Since 6.0 | Introduced. |
acf_field_post_object::render_field_validation_settings() acf field post object::render field validation settings code ACF 6.0.4
function render_field_validation_settings( $field ) {
acf_render_field_setting(
$field,
array(
'label' => __( 'Allow Null?', 'acf' ),
'instructions' => '',
'name' => 'allow_null',
'type' => 'true_false',
'ui' => 1,
)
);
}