I want to get a rrs feed using file_get_contents
$text = @file_get_contents("http://www.kalbam.lt/?feed=rss2");
But I have no idea why I don't get anything from this url (PS. with other rss feeds it works). allow_url_open is on. Any ideas?
Some services can simply check if the request is coming from a script or from the web browser. Then they can block the requests. But why not to create fake headers?!
$header=array('GET /1575051 HTTP/1.1',
'Host: adfoc.us',
'Accept:text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
'Accept-Language:en-US,en;q=0.8',
'Cache-Control:max-age=0',
'Connection:keep-alive',
'Host:adfoc.us',
'User-Agent:Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.116 Safari/537.36',
);
and then use the curl to retrive the data.