CURL.SetOptionFTPUsePret
------------------------

Whether to use PRET command.

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

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

**MBS**( **"CURL.SetOptionFTPUsePret";** /\* Whether to use PRET command. \*/  
**$curl**; /\* The CURL session handle. \*/   
**$Value**) /\* Whether to use PRET command: 1 for PRET, 0 for no PRET.e.g. 1 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| curl | The CURL session handle. | $curl |
| Value | Whether to use PRET command: 1 for PRET, 0 for no PRET. | 1 |

### Result

Returns "OK" on success.

### Description

Whether to use PRET command.  
If the value is 1, it tells curl to send a PRET command before PASV (and EPSV). Certain FTP servers, mainly drftpd, require this non-standard command for directory listings as well as up and downloads in PASV mode. Has no effect when using the active FTP transfers mode.  
See also [FTP\_USE\_PRET](https://curl.haxx.se/libcurl/c/CURLOPT_FTP_USE_PRET.html) option in CURL manual.

### See also

- [CURL.SetOptionFTPAccount](CURLSetOptionFTPAccount.md)
- [CURL.SetOptionFTPPort](CURLSetOptionFTPPort.md)
- [CURL.SetOptionFTPSSLAuth](CURLSetOptionFTPSSLAuth.md)
- [CURL.SetOptionFTPUseEPRT](CURLSetOptionFTPUseEPRT.md)
- [CURL.SetOptionFTPUseEPSV](CURLSetOptionFTPUseEPSV.md)
- [CURL.SetOptionHTTPHeader](CURLSetOptionHTTPHeader.md)
- [CURL.SetOptionRTSPRequest](CURLSetOptionRTSPRequest.md)

### Blog Entries

- [Translating Insert from URL options for CURL to MBS Plugin calls](https://www.mbsplugins.de/archive/2020-12-14/Translating_Insert_from_URL_op/monkeybreadsoftware_blog_filemaker)

Created 18th August 2014 , last changed 18th August 2014

  
[CURL.SetOptionFTPUseEPSV](CURLSetOptionFTPUseEPSV.md) - [CURL.SetOptionFailOnError](CURLSetOptionFailOnError.md)

[HTML Version](CURLSetOptionFTPUsePret.shtml)