title: Am I using Yfrog's API correctly to make a HTTP request with POST data?
body: <p>I am trying to use YFrog's API. I think I am using it correctly to try and send a HTTP POST request that is of content type XML. However, as the response body, I am always getting a 404 error for some reason. <a href="https://i.stack.imgur.com/Sv4th.png" rel="nofollow noreferrer">Here</a> is their API.</p>
  
  <p>Here is my attempt of PHP code to upload.</p>
  
  <pre><code> $data = array('media' =&gt; 'http://img253.imageshack.us/my.php?image=bfab82a545d414uo.jpg', 'username' =&gt; 'asc', 
      'password' =&gt; 'asc', 'message' =&gt; 'hi');
  
  $url = 'http://example.com/api/uploadAndPost';
  
  $req = new HTTPRequest($url);
  $req-&gt;addHeaders(array("Content-Type" =&gt; "text/xml")); 
  $req-&gt;setMethod(HTTP_METH_POST); 
  $req-&gt;addQueryData($data); $req-&gt;send();
  echo $req-&gt;getResponseBody();
  </code></pre>
  
  <p>Also for the media it says "Binary image data" does that mean a URL of the image location can not be passed to it? What does it mean?</p>