Home › Forums › General Issues › Update checbox › Reply To: Update checbox
Hi @sd
It is possible to modify a field immediately after it is loaded from the database using the acf/load_field hook. Something in the lines of this:
<?php
function my_acf_load_field( $field )
{
$field['choices'] = array(
'custom' => 'My Custom Choice'
);
return $field;
}
// acf/load_field - filter for every field
add_filter('acf/load_field', 'my_acf_load_field');
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.