javascript,js,clear,selection

Kubilay 4/12/2017 0

clear selection from javascript

JavaScript
 if (window.getSelection) {
            if (window.getSelection().empty) {  // Chrome
                window.getSelection().empty();
            } else if (window.getSelection().removeAllRanges) {  // Firefox
                window.getSelection().removeAllRanges();
            }
        } else if (document.selection) {  // IE?
            document.selection.empty();
        } 

Report Bug

Please Login to Report Bug

Reported Bugs

Comments

Please Login to Comment

Comments