curl-and-php
Re: cookie path etc
Date: Thu, 19 Aug 2004 14:08:26 +0200 (CEST)
On Thu, 19 Aug 2004, Mark wrote:
> if i specify
> $cookie_file_path = "\Zcookies.txt";
What kind of odd path is that?
> curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie_file_path);
This makes libcurl attempt to read cookies from the given file name.
> curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie_file_path);
This make libcurl write cookies to this file when you close the handle.
> where exactly should I expect to see the cookie files?
If you have received cookies, they should be written to the given file. If you
don't use an absolute path, it'll use the "current directory" of the process
that use libcurl. I have no idea where that is.
>> In the root directory of my local hard drive?
If "\Z" means the root dir, then yes. But I don't know any operating system
that uses \Z to indicate that.
If you use a unix system, "/cookies.txt" would mean a file in the root dir.
-- Daniel Stenberg -- http://curl.haxx.se -- http://daniel.haxx.se Dedicated custom curl help for hire: http://haxx.se/curl.htmlReceived on 2004-08-19