MultiPartFormEncoding (HttpRequest property): Difference between revisions
Jump to navigation
Jump to search
m (match syntax table to syntax template; edits, tags and links) |
mNo edit summary |
||
Line 1: | Line 1: | ||
{{Template:HttpRequest:MultiPartFormEncoding subtitle}} | {{Template:HttpRequest:MultiPartFormEncoding subtitle}} | ||
The <var>MultiPartFormEncoding</var> property sets and returns a <var>[[Boolean_enumeration|Boolean enumeration]]</var> (< | The <var>MultiPartFormEncoding</var> property sets and returns a <var>[[Boolean_enumeration|Boolean enumeration]]</var> (<var>True</var> or <var>False</var>) that indicates whether Multipart Form encoding support is on or off. If on (<var>True</var>), an <var>HttpRequest</var> object can send file data to a web site from either a <var>Longstring</var> or a <var>Stringlist</var>. | ||
The Post of file data using this encoding support emulates an HTML form that uses enctype="multipart/form-data" and a type="file" input field. | The Post of file data using this encoding support emulates an HTML form that uses <code>enctype="multipart/form-data"</code> and a <code>type="file"</code> input field. | ||
==Syntax== | ==Syntax== | ||
Line 9: | Line 9: | ||
<table class="syntaxTable"> | <table class="syntaxTable"> | ||
<tr><th>%currentBoolean</th> | <tr><th>%currentBoolean</th> | ||
<td>The value (< | <td>The value (<var>True</var> or <var>False</var>) of <var class="term">httpRequest</var>'s <var>MultiPartFormEncoding</var> property.</td></tr> | ||
<tr><th> | <tr><th>httpRequest</th> | ||
<td>A previously defined and instantiated <var>HttpRequest</var> object.</td></tr> | <td>A previously defined and instantiated <var>HttpRequest</var> object.</td></tr> | ||
<tr><th>newBoolean</th> | <tr><th>newBoolean</th> | ||
<td>The Boolean enumeration value (< | <td>The <var>Boolean</var> enumeration value (<var>True</var> or <var>False</var>) to assign to <var class="term">httpRequest</var>'s <var>MultiPartFormEncoding</var> property.</td></tr> | ||
</table> | </table> | ||
Latest revision as of 20:20, 21 June 2011
Use Stringlists for data transfer? (HttpRequest class)
The MultiPartFormEncoding property sets and returns a Boolean enumeration (True or False) that indicates whether Multipart Form encoding support is on or off. If on (True), an HttpRequest object can send file data to a web site from either a Longstring or a Stringlist.
The Post of file data using this encoding support emulates an HTML form that uses enctype="multipart/form-data"
and a type="file"
input field.
Syntax
%currentBoolean = httpRequest:MultiPartFormEncoding httpRequest:MultiPartFormEncoding = newBoolean
Syntax terms
%currentBoolean | The value (True or False) of httpRequest's MultiPartFormEncoding property. |
---|---|
httpRequest | A previously defined and instantiated HttpRequest object. |
newBoolean | The Boolean enumeration value (True or False) to assign to httpRequest's MultiPartFormEncoding property. |
Usage notes
- To enable file-based form uploads:
- MultiPartFormEncoding must be set to True before any AddField statements are issued, or the request is cancelled.
- For an example of code that uses the MultiPartFormEncoding property, see this AddField example.
See also
- For more general information and background about using Enumerations, see "Enumerations".