ZVON > References > DOM2 Reference

data (attribute )

Owning interface and usage:  
CharacterData.data

Member of these other interfaces:  
CDATASection, Comment, Text

Readonly:   no

Type:   DOMString

Description:  
The character data of the node that implements this interface.

Exception:  
DOMException NO_MODIFICATION_ALLOWED_ERR
This exception raises on setting when the node is readonly.
DOMException DOMSTRING_SIZE_ERR
This exception raises on retrieval when it would return more characters than fit in a DOMString variable on the implementation platform.


Example:
JavaScript:
  var txt = document.createTextNode('AAA-BBB');
  var output = txt.data;
Output:
desired your browser
AAA-BBB