4D v13.4

DOM SET XML DECLARATION

Home

 
4D v13.4
DOM SET XML DECLARATION

DOM SET XML DECLARATION 


 

DOM SET XML DECLARATION ( elementRef ; encoding {; standalone {; indentation}} )  
Parameter Type   Description
elementRef  String in XML element reference
encoding  String in XML document character set
standalone  Boolean in True = document is standalone False (default) = document is not standalone
indentation  Boolean in *** Obsolete, do not use ***

The DOM SET XML DECLARATION command allows you to define various options that are useful in creating the XML tree set using elementRef. These options concern the encoding and the standalone property of the tree:

  • encoding: Indicates the character set used in the document. By default (if the command is not called), the UTF-8 character set (compressed Unicode) is used.
  • standalone: Indicates whether the tree is standalone (True) or if it needs other files or external resources to operate (False). By default (if the command is not called or if the parameter is omitted), the tree is not standalone.
Compatibility note: The indentation parameter is kept for reasons of compatibility with previous versions of 4D but its use is not recommended in 4D v12. From now on, to specify the indentation of the document, it is strongly recommended to use the XML SET OPTIONS command.

Example  

The following example sets the encoding to use and the standalone option in the elementRef element:

 DOM SET XML DECLARATION(elementRef;"UTF-16";True)

 
PROPERTIES 

Product: 4D
Theme: XML DOM
Number: 859

 
INDEX

Alphabetical list of commands

 
HISTORY 

Created: 4D 2004
Modified: 4D v12
Renamed: 4D v12

 
SEE ALSO 

DOM Create XML Ref
XML SET OPTIONS