title: gform_after_submission Post to Third Party API
body: <p>I am trying to use the gform_after_submission hook in the functions.php file of my client's WordPress website to send this string of information to a third party API (this url was provided by the third-party client and I need to match it with every registration): 
  <a href="https://thirdpartywebsite.com/api_addNewProfile.php?gid=yourGroupID&amp;fn=John&amp;mi=E&amp;ln=Doe&amp;un=john@email.com&amp;p=testpw&amp;g=Male" rel="nofollow">https://thirdpartywebsite.com/api_addNewProfile.php?gid=yourGroupID&amp;fn=John&amp;mi=E&amp;ln=Doe&amp;un=john@email.com&amp;p=testpw&amp;g=Male</a></p>
  
  <p>This is what I set up on my functions.php file:</p>
  
  <pre><code>add_action('gform_after_submission', 'post_to_third_party', 10, 2);
  function post_to_third_party($entry, $form) {
  
      $post_url = 'https://thirdpartywebsite.com/api_addNewProfile.php';
      $body = array(
          'gid' =&gt; "yourGroupID",
          'fn' =&gt; $entry['1.3'],
          'mi' =&gt; "",
          'ln' =&gt; $entry['1.6'],
          'un' =&gt; $entry['2'],
          'p' =&gt; "test",
          'g' =&gt; $entry['3']
      );
  
      $request = new WP_Http();
      $response = $request-&gt;post($post_url, array('body' =&gt; $body));
  }
  </code></pre>
  
  <p>I'm using the GF User Registration addon so when a new member registers on my client's website they set their username and password to login to their profile page, and they should be able to login to the third-party online application with the exact same username and password that they set up through the registration form.</p>
  
  <p>For reference:</p>
  
  <ul>
  <li>fn = first name </li>
  <li>mi = middle initial (I just want to pass a blank space for middle initials for now) </li>
  <li>ln = last name </li>
  <li>un = username </li>
  <li>p = password (set to "test" for the moment) </li>
  <li>g = gender</li>
  </ul>
  
  <p>When I fill in the full url with the relevant user information everything works without any issues and I can login to the online application. I have been unable to get my Gravity Forms registration form to post the array correctly.</p>
  
  <p>If you all could point me down the right path I would greatly appreciate it.</p>