|
January 31, 2001 Deleting DOM Substrings Tips: January 2001
Yehuda Shiran, Ph.D.
|
|
As far as text manipulation is concerned,
Netscape 6 is richer in functionality than Internet Explorer. One example of this
is the deleteData()
method. Using text nodes, it deletes a substring from the text node data. You
can specify the offset of the substring and its length. Here is its syntax:
where:
Let's create a text node at the
Now we'll delete a substring
with an offset of 15 and a length 9. Click this button to get the result in
Netscape 6 ( Here is the button definition:
People who read this tip also read these tips: Look for similar tips by subject: |