Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #557183

    Hello,

    I have a checkbox in a contactform. When the user gets an autoresponder-Email this checkbox generates when clicked “: true”. How could I change this to “Ja” ?

    Thank you for Help!
    Bernd

    #557604

    Hey!

    Try adding this at the very end of your theme / child theme functions.php file:

    add_filter('avf_form_mail_field_values', 'avia_change_checkbox_return_values', 10, 4);
    function avia_change_checkbox_return_values($value, $new_post, $form_elements, $form_params){
    if($value == 'false') $value = 'No';
    if($value == 'true') $value = 'Ja';
    return $value;
    }

    Cheers!
    Josue

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.