Support » Plugin: Contact Form 7 » Beware before update to 5.2

  • Hello everyone. I just want to bring some precision on some changes that come with CF7 v5.2.

    The “setup_posted_data” method in the WPCF7_Submission class has been changed.

    So now, be sure to not use name that begin with “_” for your input field name, or it will be unset from the $posted_data array returned.

    In my case i had added a hidden field named “_form_name” in my form, which was used in the wpcf7_before_send_mail action. After updating to CF7 v5.2, i couldn’t retrieve this posted field anymore. I had to rename it to “form_name”

    Also, be sure to set attribute “do-not-store” to false when creating custom field or it will be also unset form the $posted_data variable ( $submission->get_posted_data(); )

Viewing 1 replies (of 1 total)
  • njalex1

    (@njalex1)

    @colir With 5.2.1, I am having issues trying to grab a dropdown field value from $posted_data array. It is not available anymore. Text fields and Text areas are fine.

    You mentioned “Also, be sure to set attribute “do-not-store” to false when creating custom field”. Where should I be doing this?

    Thanks.

Viewing 1 replies (of 1 total)
  • The topic ‘Beware before update to 5.2’ is closed to new replies.