title: PHP Curl post not working, nothing in post
body: <p>I have two sites on the same server:</p>
  
  <p>api.mysite.com
  john.mysite.com</p>
  
  <p>On my API site, I have a service that accepts a POSTed json array.  In my john.mysite.com site I'm calling the service and posting it using:</p>
  
  <pre><code> $info['id'] ="oo_".uniqid();
   $info['version'] ="5";
  
   $url = "http://api.mysite.com/services/addclient";
   $posted_fields = json_encode($info);
  
     $ch = curl_init($url);
      curl_setopt($ch, CURLOPT_POST, TRUE);
      curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields);
      curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
     $result = curl_exec($ch);
     echo $result;
  </code></pre>
  
  <p>When this is called, I'm not getting anything posted to the webservice.  I've gone into that code and dumped out $_POST and it's empty.  Why isn't the curl sending the data via POST?</p>
  
  <p>Thanks for any help!        </p>