This function is for use in conjunction with an ephox:button element embedded in a form for EditLive! for XML that uses the getCurrentNodeValue action. This function will allow the developer to set the value of an XML node given the ID of that node as supplied by the ephox:button using the getCurrentNodeValue action.
An integer specifying the ID of the relevant XML node.
A string containing the value to set for the XML node.
This string must be URL encoded. It is recommended that this encoding is done via a server-side URL encoding method. Encoding can be achieved using the JavaScript escape function, however, this is not recommended as the escape function does not fully comply with the URL encoding standards.
Example 17.11. SetProperties Runtime Function Example
The following sets the properties for an instance of a tag inside an instance of EditLive! for XML named editlivejs.
//set up an instance of EditLive!
var editlivejs;
editlivejs = new EditLiveXML("editlive",700,400);
editlivejs.setDownloadDirectory("editlivexml");
editlivejs.setLocalDeployment(false);
editlivejs.setConfigurationFile("sample_config.xml");
...
editlivejs.show();
...
//create a function which sets properties
function setNewNodeValue(nodeID,newValue){
editlivejs.SetXMLNodeValue(nodeID, newValue);
}Copyright 2001-2004 Ephox Corporation. All Rights Reserved.