Home › Forums › General Issues › Populating Gravity Form from ACF field in a tab layout › Reply To: Populating Gravity Form from ACF field in a tab layout
Your function would only update one Gravity Form field with the one ACF field.
Looking at the GF Docs, you can see:
add_filter( 'gform_field_value_your_parameter', 'my_custom_population_function' );
function my_custom_population_function( $value ) {
return 'boom!';
}
This snippet would populate any field with the parameter your_parameter with the result of the function my_custom_population_function. In this example, that function returns the string boom!.
So I think you would need to repeat this for each field you wish to populate.
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.