Skip to main content

XML DOM: Comment Object

The Comment object represents the content of comment nodes in a document.

The comment interface inherits the CharacterData interface representing the content of the comment.

note

There are no methods and attributes defined for the Comment object. It inherits those of its parent, CharacterData, and indirectly those of Node.

Properties

PropertyDescription
dataSets or returns the text of this node
lengthReturns the length of the text of this node

Methods

MethodDescription
appendData()Appends data to the node
deleteData()Deletes data from the node
insertData()Inserts data into the node
replaceData()Replaces data in the node
substringData()Extracts data from the node

Table of Contents