Javascript Reference
Categories: selection

javascript selection removeRange( )

@March 15, 2008, 1:22 a.m.
removeRange( )Firefox/Netscape/NN 6 IE n/a Chrome/Safari/DOM n/a  



Removes a single Range object from the current selection (not from the document tree). If you have a multiple-range selection, you can iterate through all Range objects, inspect each for some criterion, and delete the one(s) you want with the following sequence:

var oneRange;
var sel = window.getSelection( );
for (var i = 0; i< sel.rangeCount; i++) {
    oneRange = sel.getRangeAt(i);
    if (oneRange. someProperty == someDiscerningValue) {
  • Reference to one of the Range objects previously added to the current selection.
Returned Value


atorvastatin 80mg drug <a href="">order atorvastatin 40mg generic</a> order atorvastatin 40mg online
Wnklua - 4 months

Powered by Linode.