Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author fabianlindfors

    (@fabianlindfors)

    Hi!

    When you say “not taken into account”, what are you referring to? ??

    Thread Starter jhuon

    (@jhuon)

    Hello,

    Well, internally, ACF Builder generate unique keys by namespacing a field’s key by its parent field groups (see https://github.com/StoutLogic/acf-builder/wiki/generated-keys).

    So the contact form I created with Advanced Forms use input key like field_contact_form_email, and Advanced Forms save this meta_key in the database. So far so good. But when I check the submission in the admin area, the fields are empty. So I can’t see the user’s inputs.

    What is confused me is when I use the same Advanced Form from the admin, the data is saved, the submission is correctly displayed, but the meta_key stored in the database is not field_contact_form_email, just “email”, without the namespace ACF Builder internally add.

    I wonder if there is some sort of processing on key name somewhere?

    Thanks a lot for your amazing plugin ??

    Thread Starter jhuon

    (@jhuon)

    It seems there is something wrong in the create_submission() function in forms_submissions.php:

    1. $field = acf_get_field( $k ); return false
    2. $field[‘value’] = acf_format_value( $value, 0, $field ) failed because $field do not contain a name value

    Undefined index: name in plugins/advanced-custom-fields-pro/includes/acf-value-functions.php on line 121

    I use Advanced Custom Fields Pro v5.10.2, Advanced Forms v1.8.1 and ACF Builder v1.12.

    Plugin Author fabianlindfors

    (@fabianlindfors)

    That error probably indicates that ACF Builder hasn’t registered its fields with ACF when my plugin processes the form submission. Normal ACF fields will be registered at that point (ACF recommends registering fields using the acf/init action).

    At which point are you running your ACF Builder code? Are you using acf/init like in their examples on Github? https://github.com/StoutLogic/acf-builder

    Thread Starter jhuon

    (@jhuon)

    I was using the init hook from this article. I switched to acf/init and it works like a charm now. Thank you so much, it was driving me nuts!

    • This reply was modified 3 years, 5 months ago by jhuon.
    Plugin Author fabianlindfors

    (@fabianlindfors)

    Glad I could help ??

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Advanced Forms and ACF Builder’ is closed to new replies.