Home › Forums › General Issues › Radio Button image label › Reply To: Radio Button image label
Hi @GnuandYou,
Have you tried using the acf/load_field
filter to alter the choices for the radio button? Its pretty simple, try this:
add_filter('acf/load_field/name=my_radio)button', 'my_acf_load_field');
function my_acf_load_field( $field ) {
$field['choices'] = array(
'image_1' => '<img src=".../image_1.jpg" alt="image" />',
'image_2' => '<img src=".../image_2.jpg" alt="image" />'
...
);
return $field;
}
For more information about this, have a look at: 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.