Previoussibling (Xmlnode.previoussibling Property) - MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE Reference

Actionscript 2.0 language reference
Table of Contents

Advertisement

The
property of an XML node object returns the full name (including the prefix
nodeName
and the local name). You can access the local name portion of the element's name via the
property.
localName
Availability: ActionScript 1.0; Flash Player 8
Example
A directory contains a SWF file and an XML file. The XML file, named "SoapSample.xml"
contains the following:
<?xml version="1.0"?>
<soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope">
<soap:Body xmlns:w="http://www.example.com/weather">
<w:GetTemperature>
<w:City>San Francisco</w:City>
</w:GetTemperature>
</soap:Body>
</soap:Envelope>
The source for the SWF file contains the following script (note the comments for the Output
strings):
var xmlDoc:XML = new XML();
xmlDoc.ignoreWhite = true;
xmlDoc.load("SoapSample.xml");
xmlDoc.onLoad = function(success:Boolean)
{
var tempNode:XMLNode = xmlDoc.childNodes[0].childNodes[0].childNodes[0];
trace("w:GetTemperature prefix: " + tempNode.prefix); // Output: ... w
var soapEnvNode:XMLNode = xmlDoc.childNodes[0];
trace("soap:Envelope prefix: " + soapEnvNode.prefix); // Output: ... soap
}

previousSibling (XMLNode.previousSibling property)

public previousSibling : XMLNode [read-only]
An XMLNode value that references the previous sibling in the parent node's child list. The
property has a value of null if the node does not have a previous sibling node. This property
cannot be used to manipulate child nodes; use the
methods to manipulate child nodes.
removeNode()
Availability: ActionScript 1.0; Flash Player 5
1336
ActionScript classes
,
appendChild()
insertBefore()
, and

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

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

This manual is also suitable for:

Flash 8

Table of Contents

Save PDF