svn: /phpdoc/en/trunk/reference/curl/functions/ curl-setopt.xml
| From: | Joe Watkins | Date: | Mon, 25 Mar 2013 08:24:10 +0000 |
| Subject: | svn: /phpdoc/en/trunk/reference/curl/functions/ curl-setopt.xml | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-11143@lists.php.net to get a copy of this message | ||
krakjoe Mon, 25 Mar 2013 08:24:10 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=329914
Log:
#64507 adjustments to wording
Bug: https://bugs.php.net/64507 (Open) CURLOPT_*FUNCTION
options accept closures but documentation says otherwise
Changed paths:
U phpdoc/en/trunk/reference/curl/functions/curl-setopt.xml
Modified: phpdoc/en/trunk/reference/curl/functions/curl-setopt.xml
===================================================================
--- phpdoc/en/trunk/reference/curl/functions/curl-setopt.xml 2013-03-25 07:51:02 UTC (rev 329913)
+++ phpdoc/en/trunk/reference/curl/functions/curl-setopt.xml 2013-03-25 08:24:10 UTC (rev 329914)
@@ -1264,9 +1264,8 @@
</informaltable>
</para>
<para>
- <parameter>value</parameter> should be a string that is the name of a valid
- callback function for the following values of the
- <parameter>option</parameter> parameter:
+ <parameter>value</parameter> should be the name of a valid function or a Closure
+ for the following values of the <parameter>option</parameter> parameter:
<informaltable>
<tgroup cols="3">
<thead>
@@ -1279,18 +1278,18 @@
<row>
<entry
valign="top"><constant>CURLOPT_HEADERFUNCTION</constant></entry>
<entry valign="top">
- The name of a callback function where the callback function takes
- two parameters. The first is the cURL resource, the second is a
+ A callback accepting 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
+ be written when by this callback. Return the number of
bytes written.
</entry>
</row>
<row>
<entry
valign="top"><constant>CURLOPT_PASSWDFUNCTION</constant></entry>
<entry valign="top">
- The name of a callback function where the callback function takes
- three parameters. The first is the cURL resource, the second is a
+ A callback accepting 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.
</entry>
@@ -1298,8 +1297,8 @@
<row>
<entry
valign="top"><constant>CURLOPT_PROGRESSFUNCTION</constant></entry>
<entry valign="top">
- The name of a callback function where the callback function takes
- three parameters. The first is the cURL resource, the second is a
+ A callback accepting 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.
</entry>
@@ -1307,11 +1306,11 @@
<row>
<entry
valign="top"><constant>CURLOPT_READFUNCTION</constant></entry>
<entry valign="top">
- The name of a callback function where the callback function takes
- three parameters. The first is the cURL resource, the second is a
+ A callback accepting three parameters.
+ The first is the cURL resource, the second is a
stream resource provided to cURL through the option
<constant>CURLOPT_INFILE</constant>, and the third is the maximum
- amount of data to be read. The callback function must return a string
+ amount of data to be read. The callback must return a string
with a length equal or smaller than the amount of data requested,
typically by reading it from the passed stream resource. It should
return an empty string to signal <literal>EOF</literal>.
@@ -1320,10 +1319,10 @@
<row>
<entry
valign="top"><constant>CURLOPT_WRITEFUNCTION</constant></entry>
<entry valign="top">
- 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 saved by using
- this callback function. It must return the exact number of bytes written
+ A callback accepting two parameters.
+ The first is the cURL resource, and the second is a
+ string with the data to be written. The data must be saved by
+ this callback. It must return the exact number of bytes written
or the transfer will be aborted with an error.
</entry>
</row>