title: PHP file_get_contents() returns "failed to open stream: HTTP request failed!"
body: <p>I am having problems calling a url from PHP code. I need to call a service using a query string from my PHP code. If I type the url into a browser, it works ok, but if I use file-get-contents() to make the call, I get:</p>
  
  <blockquote>
    <p>Warning: file-get-contents(http://.... ) failed to open stream: HTTP request failed! HTTP/1.1 202 Accepted in ...</p>
  </blockquote>
  
  <p>The code I am using is:</p>
  
  <pre><code>$query=file_get_contents('http://###.##.##.##/mp/get?mpsrc=http://mybucket.s3.amazonaws.com/11111.mpg&amp;mpaction=convert format=flv');
  echo($query);
  </code></pre>
  
  <p>Like I said - call from the browser and it works fine. Any suggestions?</p>
  
  <p>I have also tried with another url such as:</p>
  
  <pre><code>$query=file_get_contents('http://www.youtube.com/watch?v=XiFrfeJ8dKM');
  </code></pre>
  
  <p>This works fine... could it be that the url I need to call has a second <code>http://</code> in it?</p>