Support

Account

Home Forums ACF PRO Can\'t get the name value to use $_POST Reply To: Can\'t get the name value to use $_POST

  • I’m experiencing the same issue.

    I don’t understand why acf_form wouldn’t accept a normal $_POST. How could it be getting all other values without $_POST?

        <?php
        $first_name = $_POST['acf']['field_5ae11c28116dc'];
    
        // Displays the User Profile fields.
        $options = array(
          'field_groups' => array(105),
          'submit_value' => 'Contact',
          'updated_message' => __("Thank you. Your submission has been received.", 'acf'),
          'return' => add_query_arg( 'updated', 'true', '' ),
          'post_id'		=> 'new_post',
          'new_post'		=> array(
            'post_type'		=> 'sfm_contact_requests',
            'post_status'		=> 'publish',
            'post_title' => $first_name,
          ),
        );
    
        acf_form($options);