hi everybody,
Alerady i'm coding an application with MVS in C to get html page code. It
works with a simple http:// url but if i use an ssl link it does not work.
anyone can help me ?
There is the code :
Code:
#include<stdio.h>
#include<stdlib.h>
#include<curl/curl.h>
int main()
{
CURL *session=curl_easy_init();
FILE *inFile = NULL;
if(session)
{
curl_easy_setopt(session,CURLOPT_URL,"https://mysite.com");
curl_easy_setopt(session,CURLOPT_SSL_VERIFYPEER,0);
inFile=fopen("code.html","w+");
curl_easy_setopt(session,CURLOPT_WRITEDATA,inFile);
curl_easy_setopt(session,CURLOPT_WRITEFUNCTION,fwrite);
curl_easy_perform(session);
curl_easy_cleanup(session);
fclose(inFile);
return 0;
}
thanks
--
Skander Ben Mahmoud
Administrator and Creator of http://www.Pro-Programming.net.
Programmer and Developper.
Projects released : Krypton.
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html