I'm having trouble using PHP code to call a URL. I have to use my PHP code to call service using a query string. When I use file-get-contents() to perform the call, I receive the following result instead of the expected one when I type the URL into a browser:
Warning: file-get-contents(http://.... ) failed to open stream: HTTP request failed! HTTP/1.1 202 Accepted in ...
The code I am using is:
$query=file_get_contents('http://###.##.##.##/mp/get?mpsrc=http://mybucket.s3.amazonaws.com/11111.mpg&mpaction=convert format=flv');
echo($query);
I have also tried with other URLs such as:
$query=file_get_contents('http://www.youtube.com/watch?v=XiFrfeJ8dKM');
This works fine... could it be that the URL I need to call has a second http:// in it?