diff --git a/reference/curl/functions/curl-setopt.xml b/reference/curl/functions/curl-setopt.xml
index c1457d9d2f..69223a76aa 100644
--- a/reference/curl/functions/curl-setopt.xml
+++ b/reference/curl/functions/curl-setopt.xml
@@ -39,39 +39,39 @@
The value to be set on option.
- value should be a bool for the
+ value should be a bool for the
following values of the option parameter:
- Option
- Set value to
- Notes
+ Option
+ Set value to
+ Notes
- CURLOPT_AUTOREFERER
-
+ CURLOPT_AUTOREFERER
+
&true; to automatically set the Referer: field in
requests where it follows a Location: redirect.
-
+
- CURLOPT_BINARYTRANSFER
-
+ CURLOPT_BINARYTRANSFER
+
&true; to return the raw output when
CURLOPT_RETURNTRANSFER is used.
-
+
- CURLOPT_COOKIESESSION
-
+ CURLOPT_COOKIESESSION
+
&true; to mark this as a new cookie "session". It will force libcurl
to ignore all cookies it is about to load that are "session cookies"
from the previous session. By default, libcurl always stores and
@@ -79,193 +79,193 @@
Session cookies are cookies without expiry date and they are meant
to be alive and existing for this "session" only.
-
+
- CURLOPT_CRLF
-
+ CURLOPT_CRLF
+
&true; to convert Unix newlines to CRLF newlines
on transfers.
-
+
- CURLOPT_DNS_USE_GLOBAL_CACHE
-
+ CURLOPT_DNS_USE_GLOBAL_CACHE
+
&true; to use a global DNS cache. This option is
not thread-safe and is enabled by default.
-
+
- CURLOPT_FAILONERROR
-
+ CURLOPT_FAILONERROR
+
&true; to fail silently if the HTTP code returned
is greater than or equal to 400. The default behavior is to return
the page normally, ignoring the code.
-
+
- CURLOPT_FILETIME
-
+ CURLOPT_FILETIME
+
&true; to attempt to retrieve the modification
date of the remote document. This value can be retrieved using
the CURLINFO_FILETIME option with
curl_getinfo.
-
+
- CURLOPT_FOLLOWLOCATION
-
+ CURLOPT_FOLLOWLOCATION
+
&true; to follow any
"Location: " header that the server sends as
part of the HTTP header (note this is recursive, PHP will follow as
many "Location: " headers that it is sent,
unless CURLOPT_MAXREDIRS is set).
-
+
- CURLOPT_FORBID_REUSE
-
+ CURLOPT_FORBID_REUSE
+
&true; to force the connection to explicitly
close when it has finished processing, and not be pooled for reuse.
-
+
- CURLOPT_FRESH_CONNECT
-
+ CURLOPT_FRESH_CONNECT
+
&true; to force the use of a new connection
instead of a cached one.
-
+
- CURLOPT_FTP_USE_EPRT
-
+ CURLOPT_FTP_USE_EPRT
+
&true; to use EPRT (and LPRT) when doing active
FTP downloads. Use &false; to disable EPRT and LPRT and use PORT
only.
-
+
- CURLOPT_FTP_USE_EPSV
-
+ CURLOPT_FTP_USE_EPSV
+
&true; to first try an EPSV command for FTP
transfers before reverting back to PASV. Set to &false;
to disable EPSV.
-
+
- CURLOPT_FTPAPPEND
-
+ CURLOPT_FTPAPPEND
+
&true; to append to the remote file instead of
overwriting it.
-
+
- CURLOPT_FTPASCII
-
+ CURLOPT_FTPASCII
+
An alias of
CURLOPT_TRANSFERTEXT. Use that instead.
-
+
- CURLOPT_FTPLISTONLY
-
+ CURLOPT_FTPLISTONLY
+
&true; to only list the names of an FTP
directory.
-
+
- CURLOPT_HEADER
-
+ CURLOPT_HEADER
+
&true; to include the header in the output.
-
+
CURLINFO_HEADER_OUT
-
+
&true; to track the handle's request string.
-
+
Available since PHP 5.1.3. The CURLINFO_
prefix is intentional.
- CURLOPT_HTTPGET
-
+ CURLOPT_HTTPGET
+
&true; to reset the HTTP request method to GET.
Since GET is the default, this is only necessary if the request
method has been changed.
-
+
- CURLOPT_HTTPPROXYTUNNEL
-
+ CURLOPT_HTTPPROXYTUNNEL
+
&true; to tunnel through a given HTTP proxy.
-
+
- CURLOPT_MUTE
-
+ CURLOPT_MUTE
+
&true; to be completely silent with regards to
the cURL functions.
-
+
- CURLOPT_NETRC
-
+ CURLOPT_NETRC
+
&true; to scan the ~/.netrc
file to find a username and password for the remote site that
a connection is being established with.
-
+
- CURLOPT_NOBODY
-
+ CURLOPT_NOBODY
+
&true; to exclude the body from the output.
Request method is then set to HEAD. Changing this to &false; does
not change it to GET.
-
+
- CURLOPT_NOPROGRESS
-
+ CURLOPT_NOPROGRESS
+
&true; to disable the progress meter for cURL transfers.
@@ -274,53 +274,53 @@
-
+
- CURLOPT_NOSIGNAL
-
+ CURLOPT_NOSIGNAL
+
&true; to ignore any cURL function that causes a
signal to be sent to the PHP process. This is turned on by default
in multi-threaded SAPIs so timeout options can still be used.
-
+
Added in cURL 7.10.
- CURLOPT_POST
-
+ CURLOPT_POST
+
&true; to do a regular HTTP POST. This POST is the
normal application/x-www-form-urlencoded kind,
most commonly used by HTML forms.
-
+
- CURLOPT_PUT
-
+ CURLOPT_PUT
+
&true; to HTTP PUT a file. The file to PUT must
be set with CURLOPT_INFILE and
CURLOPT_INFILESIZE.
-
+
- CURLOPT_RETURNTRANSFER
-
+ CURLOPT_RETURNTRANSFER
+
&true; to return the transfer as a string of the
return value of curl_exec instead of outputting
it out directly.
-
+
- CURLOPT_SSL_VERIFYPEER
-
+ CURLOPT_SSL_VERIFYPEER
+
&false; to stop cURL from verifying the peer's
certificate. Alternate certificates to verify against can be
specified with the CURLOPT_CAINFO option
@@ -331,49 +331,49 @@
CURLOPT_SSL_VERIFYPEER is disabled (it
defaults to 2).
-
+
&true; by default as of cURL 7.10. Default bundle installed as of
cURL 7.10.
- CURLOPT_TRANSFERTEXT
-
+ CURLOPT_TRANSFERTEXT
+
&true; to use ASCII mode for FTP transfers.
For LDAP, it retrieves data in plain text instead of HTML. On
Windows systems, it will not set STDOUT to binary
mode.
-
+
- CURLOPT_UNRESTRICTED_AUTH
-
+ CURLOPT_UNRESTRICTED_AUTH
+
&true; to keep sending the username and password
when following locations (using
CURLOPT_FOLLOWLOCATION), even when the
hostname has changed.
-
+
- CURLOPT_UPLOAD
-
+ CURLOPT_UPLOAD
+
&true; to prepare for an upload.
-
+
- CURLOPT_VERBOSE
-
+ CURLOPT_VERBOSE
+
&true; to output verbose information. Writes
output to STDERR, or the file specified using
CURLOPT_STDERR.
-
+
@@ -381,7 +381,7 @@
- value should be an integer for the
+ value should be an integer for the
following values of the option parameter:
@@ -394,81 +394,81 @@
- CURLOPT_BUFFERSIZE
-
+ CURLOPT_BUFFERSIZE
+
The size of the buffer to use for each read. There is no guarantee
this request will be fulfilled, however.
-
+
Added in cURL 7.10.
- CURLOPT_CLOSEPOLICY
-
+ CURLOPT_CLOSEPOLICY
+
Either
CURLCLOSEPOLICY_LEAST_RECENTLY_USED or
CURLCLOSEPOLICY_OLDEST.
There are three other CURLCLOSEPOLICY_
constants, but cURL does not support them yet.
-
+
CURLOPT_CONNECTTIMEOUT
-
+
The number of seconds to wait while trying to connect. Use 0 to
wait indefinitely.
-
+
- CURLOPT_CONNECTTIMEOUT_MS
-
+ CURLOPT_CONNECTTIMEOUT_MS
+
The number of milliseconds to wait while trying to connect. Use 0 to
wait indefinitely.
-
+
Added in cURL 7.16.2. Available since PHP 5.2.3.
- CURLOPT_DNS_CACHE_TIMEOUT
-
+ CURLOPT_DNS_CACHE_TIMEOUT
+
The number of seconds to keep DNS entries in memory. This
option is set to 120 (2 minutes) by default.
-
+
- CURLOPT_FTPSSLAUTH
-
+ CURLOPT_FTPSSLAUTH
+
The FTP authentication method (when is activated):
CURLFTPAUTH_SSL (try SSL first),
CURLFTPAUTH_TLS (try TLS first), or
CURLFTPAUTH_DEFAULT (let cURL decide).
-
+
Added in cURL 7.12.2.
- CURLOPT_HTTP_VERSION
-
+ CURLOPT_HTTP_VERSION
+
CURL_HTTP_VERSION_NONE (default, lets CURL
decide which version to use),
CURL_HTTP_VERSION_1_0 (forces HTTP/1.0),
or CURL_HTTP_VERSION_1_1 (forces HTTP/1.1).
-
+
- CURLOPT_HTTPAUTH
-
+ CURLOPT_HTTPAUTH
+
The HTTP authentication method(s) to use. The options are:
CURLAUTH_BASIC,
@@ -492,69 +492,69 @@
CURLAUTH_DIGEST | CURLAUTH_GSSNEGOTIATE | CURLAUTH_NTLM.
-
+
- CURLOPT_INFILESIZE
-
+ CURLOPT_INFILESIZE
+
The expected size, in bytes, of the file when uploading a file to a
remote site.
-
+
- CURLOPT_LOW_SPEED_LIMIT
-
+ CURLOPT_LOW_SPEED_LIMIT
+
The transfer speed, in bytes per second, that the transfer should be
below during the count of CURLOPT_LOW_SPEED_TIME
seconds before PHP considers the transfer too slow and aborts.
-
+
- CURLOPT_LOW_SPEED_TIME
-
+ CURLOPT_LOW_SPEED_TIME
+
The number of seconds the transfer speed should be below
CURLOPT_LOW_SPEED_LIMIT before PHP considers
the transfer too slow and aborts.
-
+
- CURLOPT_MAXCONNECTS
-
+ CURLOPT_MAXCONNECTS
+
The maximum amount of persistent connections that are allowed.
When the limit is reached,
CURLOPT_CLOSEPOLICY is used to determine
which connection to close.
-
+
- CURLOPT_MAXREDIRS
-
+ CURLOPT_MAXREDIRS
+
The maximum amount of HTTP redirections to follow. Use this option
alongside CURLOPT_FOLLOWLOCATION.
-
+
- CURLOPT_PORT
-
+ CURLOPT_PORT
+
An alternative port number to connect to.
-
+
- CURLOPT_PROTOCOLS
-
+ CURLOPT_PROTOCOLS
+
Bitmask of CURLPROTO_* values. If used, this bitmask
limits what protocols libcurl may use in the transfer. This allows you to have
@@ -580,45 +580,45 @@
CURLPROTO_ALL
-
+
Added in cURL 7.19.4.
- CURLOPT_PROXYAUTH
-
+ CURLOPT_PROXYAUTH
+
The HTTP authentication method(s) to use for the proxy connection.
Use the same bitmasks as described in
CURLOPT_HTTPAUTH. For proxy authentication,
only CURLAUTH_BASIC and
CURLAUTH_NTLM are currently supported.
-
+
Added in cURL 7.10.7.
- CURLOPT_PROXYPORT
-
+ CURLOPT_PROXYPORT
+
The port number of the proxy to connect to. This port number can
also be set in CURLOPT_PROXY.
-
+
- CURLOPT_PROXYTYPE
-
+ CURLOPT_PROXYTYPE
+
Either CURLPROXY_HTTP (default) or
CURLPROXY_SOCKS5.
-
+
Added in cURL 7.10.
- CURLOPT_REDIR_PROTOCOLS
-
+ CURLOPT_REDIR_PROTOCOLS
+
Bitmask of CURLPROTO_* values. If used, this bitmask
limits what protocols libcurl may use in a transfer that it follows to in
a redirect when CURLOPT_FOLLOWLOCATION is enabled.
@@ -628,41 +628,41 @@
which unconditionally would follow to all protocols supported.
See also CURLOPT_PROTOCOLS for protocol constant values.
-
+
Added in cURL 7.19.4.
- CURLOPT_RESUME_FROM
-
+ CURLOPT_RESUME_FROM
+
The offset, in bytes, to resume a transfer from.
-
+
- CURLOPT_SSL_VERIFYHOST
-
+ CURLOPT_SSL_VERIFYHOST
+
1 to check the existence of a common name in the
SSL peer certificate. 2 to check the existence of
a common name and also verify that it matches the hostname
provided.
-
+
- CURLOPT_SSLVERSION
-
+ CURLOPT_SSLVERSION
+
The SSL version (2 or 3) to use. By default PHP will try to determine
this itself, although in some cases this must be set manually.
-
+
- CURLOPT_TIMECONDITION
-
+ CURLOPT_TIMECONDITION
+
How CURLOPT_TIMEVALUE is treated.
Use CURL_TIMECOND_IFMODSINCE to return the
page only if it has been modified since the time specified in
@@ -673,35 +673,35 @@
effect. CURL_TIMECOND_IFMODSINCE is the
default.
-
+
- CURLOPT_TIMEOUT
-
+ CURLOPT_TIMEOUT
+
The maximum number of seconds to allow cURL functions to execute.
-
+
- CURLOPT_TIMEOUT_MS
-
+ CURLOPT_TIMEOUT_MS
+
The maximum number of milliseconds to allow cURL functions to
execute.
-
+
Added in cURL 7.16.2. Available since PHP 5.2.3.
- CURLOPT_TIMEVALUE
-
+ CURLOPT_TIMEVALUE
+
The time in seconds since January 1st, 1970. The time will be used
by CURLOPT_TIMECONDITION. By default,
CURL_TIMECOND_IFMODSINCE is used.
-
+
@@ -709,7 +709,7 @@
- value should be a string for the
+ value should be a string for the
following values of the option parameter:
@@ -722,57 +722,57 @@
- CURLOPT_CAINFO
-
+ CURLOPT_CAINFO
+
The name of a file holding one or more certificates to verify the
peer with. This only makes sense when used in combination with
CURLOPT_SSL_VERIFYPEER.
-
+
- CURLOPT_CAPATH
-
+ CURLOPT_CAPATH
+
A directory that holds multiple CA certificates. Use this option
alongside CURLOPT_SSL_VERIFYPEER.
-
+
- CURLOPT_COOKIE
-
+ CURLOPT_COOKIE
+
The contents of the "Cookie: " header to be
used in the HTTP request.
Note that multiple cookies are separated with a semicolon followed
by a space (e.g., "fruit=apple; colour=red")
-
+
- CURLOPT_COOKIEFILE
-
+ CURLOPT_COOKIEFILE
+
The name of the file containing the cookie data. The cookie file can
be in Netscape format, or just plain HTTP-style headers dumped into
a file.
-
+
- CURLOPT_COOKIEJAR
-
+ CURLOPT_COOKIEJAR
+
The name of a file to save all internal cookies to when the
connection closes.
-
+
- CURLOPT_CUSTOMREQUEST
-
+ CURLOPT_CUSTOMREQUEST
+
A custom request method to use instead of
"GET" or "HEAD" when doing
a HTTP request. This is useful for doing
@@ -789,34 +789,34 @@
-
+
- CURLOPT_EGDSOCKET
-
+ CURLOPT_EGDSOCKET
+
Like CURLOPT_RANDOM_FILE, except a filename
to an Entropy Gathering Daemon socket.
-
+
- CURLOPT_ENCODING
-
+ CURLOPT_ENCODING
+
The contents of the "Accept-Encoding: " header.
This enables decoding of the response. Supported encodings are
"identity", "deflate", and
"gzip". If an empty string, "",
is set, a header containing all supported encoding types is sent.
-
+
Added in cURL 7.10.
- CURLOPT_FTPPORT
-
+ CURLOPT_FTPPORT
+
The value which will be used to get the IP address to use
for the FTP "POST" instruction. The "POST" instruction tells
the remote server to connect to our specified IP address. The
@@ -824,21 +824,21 @@
interface name (under Unix), or just a plain '-' to use the
systems default IP address.
-
+
- CURLOPT_INTERFACE
-
+ CURLOPT_INTERFACE
+
The name of the outgoing network interface to use. This can be an
interface name, an IP address or a host name.
-
+
- CURLOPT_KRB4LEVEL
-
+ CURLOPT_KRB4LEVEL
+
The KRB4 (Kerberos 4) security level. Any of the following values
(in order from least to most powerful) are valid:
"clear",
@@ -850,12 +850,12 @@
will disable KRB4 security. Currently KRB4 security only works
with FTP transactions.
-
+
- CURLOPT_POSTFIELDS
-
+ CURLOPT_POSTFIELDS
+
The full data to post in a HTTP "POST" operation.
To post a file, prepend a filename with @ and
use the full path. This can either be passed as a urlencoded
@@ -865,122 +865,122 @@
Content-Type header will be set to
multipart/form-data.
-
+
- CURLOPT_PROXY
-
+ CURLOPT_PROXY
+
The HTTP proxy to tunnel requests through.
-
+
- CURLOPT_PROXYUSERPWD
-
+ CURLOPT_PROXYUSERPWD
+
A username and password formatted as
"[username]:[password]" to use for the
connection to the proxy.
-
+
- CURLOPT_RANDOM_FILE
-
+ CURLOPT_RANDOM_FILE
+
A filename to be used to seed the random number generator for SSL.
-
+
- CURLOPT_RANGE
-
+ CURLOPT_RANGE
+
Range(s) of data to retrieve in the format
"X-Y" where X or Y are optional. HTTP transfers
also support several intervals, separated with commas in the format
"X-Y,N-M".
-
+
- CURLOPT_REFERER
-
+ CURLOPT_REFERER
+
The contents of the "Referer: " header to be used
in a HTTP request.
-
+
- CURLOPT_SSL_CIPHER_LIST
-
+ CURLOPT_SSL_CIPHER_LIST
+
A list of ciphers to use for SSL. For example,
RC4-SHA and TLSv1 are valid
cipher lists.
-
+
- CURLOPT_SSLCERT
-
+ CURLOPT_SSLCERT
+
The name of a file containing a PEM formatted certificate.
-
+
- CURLOPT_SSLCERTPASSWD
-
+ CURLOPT_SSLCERTPASSWD
+
The password required to use the
CURLOPT_SSLCERT certificate.
-
+
- CURLOPT_SSLCERTTYPE
-
+ CURLOPT_SSLCERTTYPE
+
The format of the certificate. Supported formats are
"PEM" (default), "DER",
and "ENG".
-
+
Added in cURL 7.9.3.
- CURLOPT_SSLENGINE
-
+ CURLOPT_SSLENGINE
+
The identifier for the crypto engine of the private SSL key
specified in CURLOPT_SSLKEY.
-
+
- CURLOPT_SSLENGINE_DEFAULT
-
+ CURLOPT_SSLENGINE_DEFAULT
+
The identifier for the crypto engine used for asymmetric crypto
operations.
-
+
- CURLOPT_SSLKEY
-
+ CURLOPT_SSLKEY
+
The name of a file containing a private SSL key.
-
+
- CURLOPT_SSLKEYPASSWD
-
+ CURLOPT_SSLKEYPASSWD
+
The secret password needed to use the private SSL key specified in
CURLOPT_SSLKEY.
@@ -990,46 +990,46 @@
-
+
- CURLOPT_SSLKEYTYPE
-
+ CURLOPT_SSLKEYTYPE
+
The key type of the private SSL key specified in
CURLOPT_SSLKEY. Supported key types are
"PEM" (default), "DER",
and "ENG".
-
+
- CURLOPT_URL
-
+ CURLOPT_URL
+
The URL to fetch. This can also be set when initializing a
session with curl_init.
-
+
- CURLOPT_USERAGENT
-
+ CURLOPT_USERAGENT
+
The contents of the "User-Agent: " header to be
used in a HTTP request.
-
+
- CURLOPT_USERPWD
-
+ CURLOPT_USERPWD
+
A username and password formatted as
"[username]:[password]" to use for the
connection.
-
+
@@ -1050,39 +1050,39 @@
- CURLOPT_HTTP200ALIASES
-
+ CURLOPT_HTTP200ALIASES
+
An array of HTTP 200 responses that will be treated as valid
responses and not as errors.
-
+
Added in cURL 7.10.3.
- CURLOPT_HTTPHEADER
-
+ CURLOPT_HTTPHEADER
+
An array of HTTP header fields to set.
-
+
- CURLOPT_POSTQUOTE
-
+ CURLOPT_POSTQUOTE
+
An array of FTP commands to execute on the server after the FTP
request has been performed.
-
+
- CURLOPT_QUOTE
-
+ CURLOPT_QUOTE
+
An array of FTP commands to execute on the server prior to the FTP
request.
-
+
@@ -1099,43 +1099,34 @@
Option
Set value to
- Notes
- CURLOPT_FILE
-
+ CURLOPT_FILE
+
The file that the transfer should be written to. The default
is STDOUT (the browser window).
-
-
- CURLOPT_INFILE
-
+ CURLOPT_INFILE
+
The file that the transfer should be read from when uploading.
-
-
- CURLOPT_STDERR
-
+ CURLOPT_STDERR
+
An alternative location to output errors to instead of
STDERR.
-
-
- CURLOPT_WRITEHEADER
-
+ CURLOPT_WRITEHEADER
+
The file that the header part of the transfer is written to.
-
-
@@ -1151,67 +1142,56 @@
Option
Set value to
- Notes
- CURLOPT_HEADERFUNCTION
-
+ CURLOPT_HEADERFUNCTION
+
The name of a callback function where the callback function takes
two parameters. The first is the cURL resource, the second is a
string with the header data to be written. The header data must
be written when using this callback function. Return the number of
bytes written.
-
-
- CURLOPT_PASSWDFUNCTION
-
+ CURLOPT_PASSWDFUNCTION
+
The name of a callback function where the callback function takes
three parameters. The first is the cURL resource, the second is a
string containing a password prompt, and the third is the maximum
password length. Return the string containing the password.
-
-
- CURLOPT_PROGRESSFUNCTION
-
+ CURLOPT_PROGRESSFUNCTION
+
The name of a callback function where the callback function takes
three parameters. The first is the cURL resource, the second is a
file-descriptor resource, and the third is length. Return the
string containing the data.
-
-
- CURLOPT_READFUNCTION
-
+ CURLOPT_READFUNCTION
+
The name of a callback function where the callback function takes
two parameters. The first is the cURL resource, and the second is a
string with the data to be read. The data must be read by using this
callback function. Return the number of bytes read. Return 0 to signal
EOF.
-
-
- CURLOPT_WRITEFUNCTION
-
+ CURLOPT_WRITEFUNCTION
+
The name of a callback function where the callback function takes
two parameters. The first is the cURL resource, and the second is a
string with the data to be written. The data must be written by using
this callback function. Must return the exact number of bytes written
or this will fail.
-
-