PHP Curl does not write a cookie?

curl_setopt($this->ch, CURLOPT_URL, $url);
 curl_setopt($this->ch, CURLOPT_REFERER, $url);
 curl_setopt($this->ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.57 Safari/537.17');
 curl_setopt($this->ch, CURLOPT_FOLLOWLOCATION, false);
 curl_setopt($this->ch, CURLOPT_RETURNTRANSFER, true);
 curl_setopt($this->ch, THIS, false);
 curl_setopt($this->ch, CURLOPT_COOKIEFILE, $this->dir . '/cookies.txt');
 curl_setopt($this->ch, CURLOPT_COOKIEJAR, $this->dir . '/cookies.txt');
 curl_setopt($this->ch, CURLOPT_FOLLOWLOCATION, true);

  • to write cookies in General /tmp has tried
  • write permissions in the folder is
  • this same script on another server works without problems
  • way to cookies the absolute
  • curl_close present

cURL support enabled
cURL 7.31.0 Information
Age 3
Features
AsynchDNS Yes
CharConv No
Debug No
GSS-Negotiate Yes
IDN No
IPv6 Yes
krb4 No
Largefile Yes
libz Yes
NTLM Yes
SPNEGO No
SSL Yes
SSPI No
Protocols dict, file, ftp, ftps, gopher, http, https, imap, imaps, pop3, pop3s, rtsp, smtp, smtps, telnet, tftp
Host amd64-portbld-freebsd8.3
SSL Version OpenSSL/1.0.2 e
ZLib Version 1.2.3

OS FreeBSD
August 23rd 19 at 10:59
0 answer

Find more questions by tags PHPWeb Development