libURLMultipartFormData | ||||||||||||||||||||||
Type | function | |||||||||||||||||||||
Dictionary | LCS | |||||||||||||||||||||
Library | LiveCode Script | |||||||||||||||||||||
Syntax |
| |||||||||||||||||||||
Associations | internet library | |||||||||||||||||||||
Summary | libURLMultipartFormData formats data in the way described in RFC 1867. | |||||||||||||||||||||
Introduced | 2.5 | |||||||||||||||||||||
OS | mac, windows, linux, web | |||||||||||||||||||||
Platforms | desktop, server | |||||||||||||||||||||
Parameters |
| |||||||||||||||||||||
Example |
| |||||||||||||||||||||
Values |
| |||||||||||||||||||||
Related | Keyword: $_POST, $_POST_BINARY, $_POST_RAW Command: libURLSetExpect100, post Function: libURLFormData, libURLMultipartFormAddPart Glossary: argument, function, LiveCode custom library, parameter, standalone application, Standalone Application Settings Library: Internet library, library | |||||||||||||||||||||
Security | network | |||||||||||||||||||||
Description | The function can be called in a number of ways depending on the parameters passed. In all cases, the first parameter must be a variable which will be filled with the form data. The function will return empty if successful, or an error message if it fails (for example, if it couldn't open a file).
The standard way to call the function is with pairs of name/value parameters. You can also pass in an array instead of pairs of parameters. This could be useful if there are many parts to a form. The array must be numerically indexed, and each element should contain the part name and part value, separated by a comma. So (modifying the above example):
You can also call the function with no arguments except formData. This will return an "empty" form. Basically, line 1 is the header, and line 2 is the final boundary mark of the form. It is of no use by itself, but it can be used with libURLMultipartFormAddPart.
See also RFC 1867. |