Page 1 of 1

cookies for a https website

Posted: Tue May 06, 2008 1:11 am
by chdnrajasekhar
Hi everyone,

I'm trying to get the cookies of a https url .can any one help me out . I had a code with me , previously i had used it for getting the cookies for a http url . when i use the same code im not getting the cookies . im giving the code below.

$ch = curl_init();
curl_setopt ($ch, CURLOPT_URL, $url);
curl_setopt ($ch, CURLOPT_COOKIESESSION, true);
curl_setopt ($ch, CURLOPT_COOKIEJAR, "C:/CookieJar.txt");
curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, true);
$output = curl_exec ($ch);
curl_close ($ch);



THANQ

Rajasekhar.

Re: cookies for a https website

Posted: Thu May 08, 2008 1:17 pm
by John Cartwright
Why is this in PHPDN forum?


Try adding

Code: Select all

curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);

Moved to PHP-Code.