EasyManua.ls Logo

MACROMEDIA FLASH MX 2004 - ACTIONSCRIPT - Page 755

MACROMEDIA FLASH MX 2004 - ACTIONSCRIPT
816 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
XML.appendChild() 755
Example
This 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'");
This next 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 = ["Content-Type", "text/plain", "X-ClientAppVersion", "2.0"];
my_xml.addRequestHeader(headers);
See also
LoadVars.addRequestHeader()
XML.appendChild()
Availability
Flash Player 5.
Usage
my_xml.appendChild(childNode)
Parameters
childNode
The child node to be added to the specified XML object’s child list.
Returns
Nothing.
Description
Method; appends the specified child node to the XML objects child list. The appended child
node is placed in the tree structure once removed from its existing parent node, if any.
Example
The following example clones the last node from doc1 and appends it to doc2.
doc1 = new XML(src1);
doc2 = new XML();
node = doc1.lastChild.cloneNode(true);
doc2.appendChild(node);

Table of Contents

Related product manuals