title: CURL - No response and no error
body: <p>I'm hoping someone could help me as I'm getting no response, no error, and no indication of why my CURL is not working here. I've searched around and added a clause to ignore the SSL (SSLVerify is set to false) and tried numerous ways to get a response.</p>
  
  <p>May someone please point me in the right direction?</p>
  
  <p>Thanks!</p>
  
  <pre><code>&lt;?php
  function sendContactInfo() {
  
  //Process a new form submission in HubSpot in order to create a new Contact.
  
  $hubspotutk = $_COOKIE['hubspotutk'];  //grab the cookie from the visitors browser.
  $ip_addr = $_SERVER['REMOTE_ADDR'];  //IP address too.
  $hs_context = array(
          'hutk' =&gt; $hubspotutk,
          'ipAddress' =&gt; $ip_addr,
          'pageUrl' =&gt; 'https://www.myfoodstorage.com/onestepcheckout/',
          'pageTitle' =&gt; 'MyFoodStorage.com Cart Checkout'
      );
  $hs_context_json = json_encode($hs_context);
  
  //Need to populate these varilables with values from the form.
  $str_post = "firstname=" . urlencode($firstname)
          . "&amp;lastname=" . urlencode($lastname)
          . "&amp;email=" . urlencode($email)
          . "&amp;phone=" . urlencode($telephone)
          . "&amp;address=" . urlencode($street)
          . "&amp;city=" . urlencode($city)
          . "&amp;state=" . urlencode($region)
          . "&amp;country=" . urlencode($country)
          . "&amp;hs_context=" . urlencode($hs_context_json);  //Leave this one be :)
  
   //replace the values in this URL with your portal ID and your form GUID
  $endpoint = 'https://forms.hubspot.com/uploads/form/v2/234423/4a282b6b-2ae2-4908-bc82-b89874f4e8ed';
  
  $ch = @curl_init();
  @curl_setopt($ch, CURLOPT_POST, true);
  @curl_setopt($ch, CURLOPT_POSTFIELDS, $str_post);
  @curl_setopt($ch, CURLOPT_URL, $endpoint);
  @curl_setopt($ch, CURLOPT_HTTPHEADER, array('application/x-www-form-urlencoded'));
  @curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  @curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
  $response = @curl_exec($ch);
  $info = @curl_getinfo($ch);
  @curl_close($ch);
  }
  
  echo sendContactInfo();
  echo $response;
  print_r($info);
  ?&gt;
  </code></pre>