CURL.SetOptionPostFieldSize
---------------------------

Sets the length of post field data.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [CURL](component_CURL.md) | [2.5](newinversion25.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "CURL.SetOptionPostFieldSize"; curl; Value ) 

**MBS**( **"CURL.SetOptionPostFieldSize";** /\* Sets the length of post field data. \*/  
**$curl**; /\* The CURL session handle. \*/   
**$Value**) /\* The post fields data size in bytes.e.g. 1234 \*/ 

(old name: CURL.SetOptionPostFieldSizeLarge)

### Parameters

| Parameter | Description | Example |
|---|---|---|
| curl | The CURL session handle. | $curl |
| Value | The post fields data size in bytes. | 1234 |

### Result

Returns "OK" on success.

### Description

Sets the length of post field data.  
If you want to post data to the server without letting libcurl do a string length() to measure the data size, this option must be used. When this option is used you can post fully binary data, which otherwise is likely to fail. If this size is set to -1, the library will use strlen() to get the size.  
See also [POSTFIELDSIZE](https://curl.haxx.se/libcurl/c/CURLOPT_POSTFIELDSIZE.html) option in CURL manual.

### See also

- [CURL.GetOptionPostFields](CURLGetOptionPostFields.md)
- [CURL.SetOptionInFileSize](CURLSetOptionInFileSize.md)
- [CURL.SetOptionMaxFileSize](CURLSetOptionMaxFileSize.md)
- [CURL.SetOptionPostFields](CURLSetOptionPostFields.md)
- [CURL.SetOptionPostRedir](CURLSetOptionPostRedir.md)

### Blog Entries

- [MBS Filemaker Plugin, version 3.3pr1](https://www.mbsplugins.de/archive/2013-05-24/MBS_Filemaker_Plugin_version_3/monkeybreadsoftware_blog_filemaker)

Created 18th August 2014 , last changed 3th February 2023

  
[CURL.SetOptionPost](CURLSetOptionPost.md) - [CURL.SetOptionPostFields](CURLSetOptionPostFields.md)

[HTML Version](CURLSetOptionPostFieldSize.shtml)