I am trying to use libcurl.net to connect to a server and return the json from it. But instead of returning the JSON, it returns "CURLE_OK". Heres my code:
Curl.GlobalInit((int)CURLinitFlag.CURL_GLOBAL_WIN32);
Easy easy = new Easy();
var agent = "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.0.3705; .NET CLR 1.1.4322)";
easy.SetOpt(CURLoption.CURLOPT_URL, string.Format("http://vikinglogue.com/api/get_posts/?page={0}", currentPage));
easy.SetOpt(CURLoption.CURLOPT_HTTPGET, 1);
easy.SetOpt(CURLoption.CURLOPT_USERAGENT, agent);
easy.SetOpt(CURLoption.CURLOPT_TRANSFERTEXT, 1);
var responce = easy.Perform();
MessageBox.Show(responce.ToString());
easy.Cleanup();
Anyone have any idea what I'm doing wrong here? Please don't suggest an answer using WebClient, because, I can't use it (not by choice). Thanks.