aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2002-03-05 09:01:58 +0000
committerDaniel Stenberg <daniel@haxx.se>2002-03-05 09:01:58 +0000
commitcda16297d141ab5f6d68050b5541f0362cd3de04 (patch)
tree294607fe00a1faf67b46ab6020244b1a059f38ab /docs
parentd6c9a72e1584d6d3a967caf587a9f1a8fa1a4bd2 (diff)
added text to the progress chapter
Diffstat (limited to 'docs')
-rw-r--r--docs/libcurl-the-guide25
1 files changed, 24 insertions, 1 deletions
diff --git a/docs/libcurl-the-guide b/docs/libcurl-the-guide
index f0f5a79d6..c6c1cea6b 100644
--- a/docs/libcurl-the-guide
+++ b/docs/libcurl-the-guide
@@ -470,7 +470,30 @@ HTTP POSTing
Showing Progress
- [ built-in progress meter, progress callback ]
+ For historical and traditional reasons, libcurl has a built-in progress meter
+ that can be switched on and then makes it presents a progress meter in your
+ terminal.
+
+ Switch on the progress meter by, oddly enough, set CURLOPT_NOPROGRESS to
+ FALSE. This option is set to TRUE by default.
+
+ For most applications however, the built-in progress meter is useless and
+ what instead is interesting is the ability to specify a progress
+ callback. The function pointer you pass to libcurl will then be called on
+ irregular intervals with information about the current transfer.
+
+ Set the progress callback by using CURLOPT_PROGRESSFUNCTION. And pass a
+ pointer to a function that matches this prototype:
+
+ int progress_callback(void *clientp,
+ double dltotal,
+ double dlnow,
+ double ultotal,
+ double ulnow);
+
+ If any of the input arguments is unknown, a 0 will be passed. The first
+ argument, the 'clientp' is the pointer you pass to libcurl with
+ CURLOPT_PROGRESSDATA. libcurl won't touch it.
libcurl with C++