XML.docTypeDecl
759
XML.createTextNode()
Availability
Flash Player 5.
Usage
my_xml
.createTextNode(
text
)
Parameters
text
The text used to create the new text node.
Returns
Nothing.
Description
Method; creates a new XML text node with the specified text. The new node initially has no
parent, and text nodes cannot have children or siblings. This method returns a reference to the
XML object representing the new text node. This method and
createElement()
are the
constructor methods for creating nodes for an XML object.
XML.docTypeDecl
Availability
Flash Player 5.
Usage
my_xml
.
XMLdocTypeDecl
Description
Property; specifies information about the XML document’s
DOCTYPE
declaration. After the XML
text has been parsed into an XML object, the
XML.docTypeDecl
property of the XML object is
set to the text of the XML document’s
DOCTYPE
declaration. For example,
<!DOCTYPE greeting
SYSTEM "hello.dtd">
. This property is set using a string representation of the
DOCTYPE
declaration, not an XML node object.
The ActionScript XML parser is not a validating parser. The
DOCTYPE
declaration is read by the
parser and stored in the
docTypeDecl
property, but no DTD validation is performed.
If no
DOCTYPE
declaration was encountered during a parse operation,
XML.docTypeDecl
is set to
undefined.
XML.toString()
outputs the contents of
XML.docTypeDecl
immediately after the
XML declaration stored in
XML.xmlDecl
, and before any other text in the XML object. If
XML.docTypeDecl
is undefined, no
DOCTYPE
declaration is output.
Example
The following example uses
XML.docTypeDecl
to set the
DOCTYPE
declaration for an XML object:
my_xml
.docTypeDecl = "<!DOCTYPE greeting SYSTEM \"hello.dtd\">";
See also
XML.toString()
,
XML.xmlDecl
Summary of Contents for FLASH MX 2004 - ACTIONSCRIPT
Page 1: ...ActionScript Reference Guide...
Page 8: ...8 Contents...
Page 12: ......
Page 24: ...24 Chapter 1 What s New in Flash MX 2004 ActionScript...
Page 54: ...54 Chapter 2 ActionScript Basics...
Page 80: ...80 Chapter 3 Writing and Debugging Scripts...
Page 82: ......
Page 110: ...110 Chapter 5 Creating Interaction with ActionScript...
Page 112: ......
Page 120: ...120 Chapter 6 Using the Built In Classes...
Page 176: ......
Page 192: ...192 Chapter 10 Working with External Data...
Page 202: ...202 Chapter 11 Working with External Media...
Page 204: ......
Page 782: ...782 Chapter 12 ActionScript Dictionary...
Page 793: ...Other keys 793 221 222 Key Key code...
Page 794: ...794 Appendix C Keyboard Keys and Key Code Values...
Page 798: ...798 Appendix D Writing Scripts for Earlier Versions of Flash Player...
Page 806: ...806 Appendix E Object Oriented Programming with ActionScript 1...
Page 816: ...816 Index...