MACROMEDIA FLEX-FLEX ACTIONSCRIPT LANGUAGE Reference page 461

Actionscript language reference
Table of Contents

Advertisement

/* output (line breaks added for clarity):
<house>
<kitchen>
<bathroom>linoleum</bathroom>
<foyer />
</house>
*/
If you then change the setting of
code entirely, the fourteen space characters in the
...
// set the ignoreWhite property to false (default value)
flooring.ignoreWhite = false;
...
/* output (line breaks added for clarity):
<house>
<kitchen>
<bathroom>linoleum</bathroom>
<foyer>
</house>
*/
XML.insertBefore()
Availability
Flash Player 5.
Usage
my_xml.insertBefore(childNode:XMLNode, beforeNode:XMLNode) : Void
Parameters
The XMLNode object to be inserted.
childNode
The XMLNode object before the insertion point for the
beforeNode
Returns
Nothing.
Description
Method; inserts a new child node into the XML object's child list, before the
If the
beforeNode
method. If
beforeNode
Example
The following example is an excerpt from the
// create a copy of the middle node using cloneNode()
var middle2:XMLNode = middle.cloneNode(false);
// insert the clone node into rootNode between the middle and youngest nodes
rootNode.insertBefore(middle2, youngest);
ceramic tile
</kitchen>
flooring.ignoreWhite
ceramic tile
</kitchen>
</foyer>
parameter is undefined or
is not a child of
to
false
tag will be preserved:
foyer
, the node is added using the
null
, the insertion fails.
my_xml
XML.cloneNode()
, or simply remove that line of
.
childNode
beforeNode
appendChild()
example:
XML.insertBefore()
node.
461

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLEX-FLEX ACTIONSCRIPT LANGUAGE and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flex

Table of Contents