User Guide

720 ActionScript classes
If multiple calls are made to set the same header name, each successive value replaces the value
set in the previous call.
You cannot add or change the following standard HTTP headers using 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.
Availability: ActionScript 1.0; Flash Lite 2.0
Parameters
header:Object - A string that represents an HTTP request header name.
headerValue:String - A string that represents the value associated with header.
Example
The following example adds a custom HTTP header named
SOAPAction with a value of Foo
to an XML object named
my_xml:
my_xml.addRequestHeader("SOAPAction", "'Foo'");
The following example creates an array named headers that contains two alternating HTTP
headers and their associated values. The array is passed as a parameter to the
addRequestHeader() method.
var headers:Array = new Array("Content-Type", "text/plain",
"X-ClientAppVersion", "2.0");
my_xml.addRequestHeader(headers);
See also
addRequestHeader (LoadVars.addRequestHeader method)
contentType (XML.contentType property)
public contentType : String
The MIME content type that is sent to the server when you call the XML.send() or
XML.sendAndLoad() method. The default is application/x-www-form-urlencoded, which
is the standard MIME content type used for most HTML forms.
Availability: ActionScript 1.0; Flash Lite 2.0