Dreamweaver.createxmldocument(), Dreamweaver.exporttemplatedataasxml() – Adobe Dreamweaver API Reference CS5 User Manual
Page 260

255
DREAMWEAVER API REFERENCE
Document
Last updated 8/27/2013
dreamweaver.createXMLDocument()
Availability
Dreamweaver MX.
Description
Creates and opens a new XML file, which is empty except for the XML directive.
Arguments
None.
Returns
The DOM of the new XML file.
Example
The following example creates a new document, which is empty except for the XML directive:
var theDOM = dreamweaver.createXMLDocument("document");
dreamweaver.exportTemplateDataAsXML()
Availability
Dreamweaver MX.
Description
Exports the current document to the specified file as XML. This function operates on the document that has focus,
which must be a template. If you do not specify a filename argument, Dreamweaver MX opens a dialog box to request
the export file string.
Arguments
{filePath}
•
The filePath argument, which is optional, is a string that specifies the filename to which Dreamweaver exports the
template. Express the filePath argument as a URL file string, such as
"file:///c|/temp/mydata.txt"
.
Returns
Nothing.
Enabler
See “
dreamweaver.canExportTemplateDataAsXML()
Example
if(dreamweaver.canExportTemplateDataAsXML())
{
dreamweaver.exportTemplateDataAsXML("file:///c|/dw_temps/mytemplate.txt")
}