I want to add a custom setting to a specific field type as described in the first example here: https://www.advancedcustomfields.com/resources/adding-custom-settings-fields/
So that these settings are only applied to the
textarea field type, I added
/type= textarea to the
On adding a new field to the field group and changing field type from
text (which is the default field type) to
textarea the additional setting is not displayed. The additional setting is only displayed, when the field group settings page is updated or loaded if it is already saved.
How can I get the settings displayed when changing the field type?
Have you tried to call the function with a priority of less than 10?
You need to render the settings before ACF does.
Thank you, @James
After playing around with the priority, I found my mistake. I called the
acf/render_field_settings action in a function that itself has been called in with the action
If I call the
acf/render_field_settings action in the
__construct() or if I add a function called on
admin_init it works.
Thanks for your help.