Support

Account

Home Forums Add-ons Options Page how to use acf/load_field dynamically

Helping

how to use acf/load_field dynamically

  • for using this filter we have two ways :
    1_using this filter in plugin :
    we have a custom taxonomy that we want to use it in filter .
    because our taxonomy should be registered with init action (init action run after loading plugins)
    so we have no access to custom taxonomy . what should we do for both using this filter in plugin and access to custom taxonomy?

    2_ using this filter in functions.php
    in this case filter works . But only in ACF admin .filter add taxonomies to choice field of ACF admin,while we want to use our taxonomies in type of checkbox fields in our custom theme options,

    How can I do it?

  • acf/load_field only happens when the field is loaded and this should happen after the init action is fired. If the taxonomy is not available when acf/load_field is fired then there is something, either in your code or someone else’s code, that is causing ACF to initialize earlier than it should be. This can happen by calling any acf function before init has fired.

Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘how to use acf/load_field dynamically’ is closed to new replies.