Jump to content

Curl Problem


spyworld

Recommended Posts

Browser result is different than php curl output. How to fix it?

 

http://kat.ph/applications/?rss=1

 

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "http://kat.ph/applications/?rss=1");
curl_setopt($ch, CURLOPT_VERBOSE, 0);
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1");
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HTTPHEADER, array("Content-Type: application/rss+xml; charset=ISO-8859-1", "Content-length: "));
$result = curl_exec($ch);
curl_close($ch);
echo $result;

Link to comment
https://forums.phpfreaks.com/topic/272090-curl-problem/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.