Hi, I have a select field which is empty and I want to fill it with acf/load_value.
I used the following code, but the select field is empty.
If I insert something into the select field via the dashboard in ACF, it is displayed in the dashboard, but the $value is also empty.
add_filter('acf/load_value/key=field_67878669b82ab', 'loadStartLocation', 10 , 3);
function loadStartLocation( $value, $post_id, $field ) {
$value = array('Hamburg', 'Bremen');
return $value;
}
array(
'key' => 'field_67878669b82ab',
'label' => 'Startort',
'name' => 'product_ballon_start_location',
'aria-label' => '',
'type' => 'select',
'instructions' => '',
'required' => 0,
'conditional_logic' => 0,
'wrapper' => array(
'width' => '',
'class' => '',
'id' => '',
),
'choices' => array(
'cool' => 'cool',
),
'default_value' => false,
'return_format' => 'value',
'multiple' => 0,
'allow_null' => 0,
'allow_in_bindings' => 0,
'ui' => 0,
'ajax' => 0,
'placeholder' => '',
),