Support

Account

Home Forums Front-end Issues acf_form() Post Title

Solving

acf_form() Post Title

  • I am using the acf_form() function to display a form on a page. I am using “title=true” to include the post_title in the form.

    Is there any way to change the “Title” text for the form element label? I want it to say “Customer Name” instead.

  • Yes you can do something like this:

    function my_acf_prepare_field($field) {
    	$field['label'] = 'Customer Name';
           return $field;
    }
    add_filter('acf/prepare_field/name=_post_title', 'my_acf_prepare_field');
Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘acf_form() Post Title’ is closed to new replies.