deleteData method (comment, CommentNode, TextNode)
Removes the specified part of the text content of the current TextNode, CommentNode or comment element.
The appendData, insertData and replaceData methods and the data property can also be used to manipulate the text content of the current element.
You can find the related objects in the Supported by objects section below.
|Required. Integer that specifies the start position of the contents to remove.|
|Required. Integer that specifies the number of characters to remove.|
This method has no return value.
Example HTML code 1:
This example illustrates the use of the deleteData method:
Did you find this example helpful?
User Contributed Comments