Pro Forms – Preselect option in select field

I have an ACF select field (f_stage) using an number of options. When someone selects a value for that field it saves back to ACF fine but when you go back to the page it is defaulting to the first option in the list. I cannot get it to pick up the actual value in the field. This is the same problem someone else was having but that post does not have an answer. I am using Selected if… option value contains. How do I solve this issue?

Hi Debra,

we currently have a bug when using the conditional selection and a brf_acf_field tag. Until it’s fixed, the simplest workaround would be to:

  1. Create a function in your functions.php
function get_some_acf_value($field_name, $post_id) {
    return get_field($field_name, $post_id);
}
  1. Make sure it’s allowed to run
add_filter( 'bricks/code/echo_function_names', function() {
  return [
     'get_some_acf_value',
  ];
});
  1. Replace the brf_acf dd tag with {echo:get_some_acf_value('some_select', {url_parameter:id})} or in your case, {echo:get_some_acf_value('tst_stage', {url_parameter:id})}

Note that different ACF fields have different return options. The Basic workaround above will work if the return option is set to only return the value. If your setup is different, feel free to post some screenshots of your field setup so I can adapt the solution.

Thank you for responding. Much appreciated.
Implemented and works perfectly.