curl_formget - Online Linux Manual PageSection : 3
Updated : October 31, 2021
Source : libcurl 7.82.0
Note : libcurl Manual
NAMEcurl_formget - serialize a previously built multipart/formdata HTTP POST chain
SYNOPSIS#include <curl/curl.h>
int curl_formget(struct curl_httppost * form, void *userp,
curl_formget_callback append );
DESCRIPTION
curl_formget() is used to serialize data previously built/appended with curl_formadd(3). Accepts a void pointer as second argument named userp which will be passed as the first argument to the curl_formget_callback function. typedef size_t (*curl_formget_callback)(void *userp, const char *buf, size_t len); The curl_formget_callback will be executed for each part of the HTTP POST chain. The character buffer passed to the callback must not be freed. The callback should return the buffer length passed to it on success. If the CURLFORM_STREAM option is used in the formpost, it will prevent curl_formget(3) from working until you have performed the actual HTTP request as only then will libcurl get the actual read callback to use!
EXAMPLE size_t print_httppost_callback(void *arg, const char *buf, size_t len)
{
fwrite(buf, len, 1, stdout);
(*(size_t *) arg) += len;
return len;
}
size_t print_httppost(struct curl_httppost *post)
{
size_t total_size = 0;
if(curl_formget(post, &total_size, print_httppost_callback)) {
return (size_t) -1;
}
return total_size;
}
AVAILABILITY
This function was added in libcurl 7.15.5. The form API is deprecated in libcurl 7.56.0.
RETURN VALUE0 means everything was ok, non-zero means an error occurred
SEE ALSOcurl_formadd(3), curl_mime_init (3)" 0
Johanes Gumabo
Data Size : 5,538 byte
man-curl_formget.3Build : 2024-12-05, 20:55 :
Visitor Screen : x
Visitor Counter ( page / site ) : 2 / 182,901
Visitor ID : :
Visitor IP : 3.143.24.110 :
Visitor Provider : AMAZON-02 :
Provider Position ( lat x lon ) : 39.962500 x -83.006100 : x
Provider Accuracy Radius ( km ) : 1000 :
Provider City : Columbus :
Provider Province : Ohio , : ,
Provider Country : United States :
Provider Continent : North America :
Visitor Recorder : Version :
Visitor Recorder : Library :
Online Linux Manual Page : Version : Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.05
Online Linux Manual Page : Library : lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page : Library : lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base : Version : Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base : Library : lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36
Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.