Support

Account

Home Forums Front-end Issues Prevent acf_form_head Being Added Twice Reply To: Prevent acf_form_head Being Added Twice

  • ACF form head should not be run in the admin, normally.

    The action I referenced acf/submit_form is run during acf_form_head(). If this action has been done that means that acf_form_head() was already called somewhere else. There are other actions as well that could be used but this one seemed the most likely.

    I would also check the the other thing.

    
    if (!is_admin() && did_action('acf/submit_form')) == 0) {
      acf_form_head();
    }