IO.setSaveXMLFunction
Set a new function to save XML documents.
An example:
IO.setSaveXMLFunction(function (uri, xmlDocument)
{
// Use uri and xmlDocument to save the XML
var response = HTTPTools.postXML(uri, xmlDocument, "UTF-8");
// See what the response was from the server
if (response != "OK")
{
alert("Couldn't save: " + response);
return false;
}
else
return true;
});
- Documentation
- › API
- › Global objects API
- › IO.setSaveXMLFunction
IO.setSaveXMLFunction( saveFunction : Function)
: Function)Arguments
- saveFunction
- Function. The new save function. This function has two arguments: the URI which identifies the document and the XMLDOMDocument to save. The URI can be set on the XopusDocument using setDocumentURI. To indicate failure and prevent the save button from greying out, return false from your save frunction.