LoadVars.contentType 427
The following standard HTTP headers cannot be added or changed with this method: Accept-
Ranges
, Age, Allow, Allowed, Connection, Content-Length, Content-Location, Content-
Range
, ETag, Host, Last-Modified, Locations, Max-Forwards, Proxy-Authenticate, Proxy-
Authorization
, Public, Range, Retry-After, Server, TE, Trailer, Transfer-Encoding,
Upgrade, URI, Vary, Via, Warning, and WWW-Authenticate.
Example
This example adds a custom HTTP header named SOAPAction with a value of Foo to the
my_lv object.
my_lv.addRequestHeader("SOAPAction", "'Foo'");
This next example creates an array named headers that contains two alternating HTTP headers
and their associated values. The array is passed as an argument to
addRequestHeader().
var headers = ["Content-Type", "text/plain", "X-ClientAppVersion", "2.0"];
my_lv.addRequestHeader(headers);
See also
XML.addRequestHeader()
LoadVars.contentType
Availability
Flash Player 6.
Usage
my_lv.contentType
Description
Property; the MIME type that is sent to the server when you call LoadVars.send() or
LoadVars.sendAndLoad(). The default is application/x-www-form-urlencoded.
See also
LoadVars.send()
, LoadVars.sendAndLoad()