For the problematic browser:
document.selection.empty()
For other browsers:
window.getSelection().removeAllRanges()
More Related Contents:
- Persisting the changes of range objects after selection in HTML
- contenteditable div backspace and deleting text node problems
- Cross Browser Selection Range Library?
- How To Wrap / Surround Highlighted Text With An Element
- Highlight text range using JavaScript
- How can I get the DOM element which contains the current selection?
- JavaScript eyedropper (tell color of pixel under mouse cursor)
- Programmatically select text in a contenteditable HTML element?
- Coordinates of selected text in browser page
- How can I highlight the text of the DOM Range object?
- Understanding what goes on with textarea selection with JavaScript
- Prevent selection in HTML
- replace innerHTML in contenteditable div
- JavaScript Array: get “range” of items
- jQuery – select all text from a textarea
- Getting selected text position
- How to get nodes lying inside a range with javascript?
- Creating a collapsed range from a pixel position in FF/Webkit
- window.getSelection() gives me the selected text, but I want the HTML
- Calculate Position of selected text javascript/JQuery?
- Generate colors between red and green for an input range [duplicate]
- Javascript: Generate a random number within a range using crypto.getRandomValues
- Get selected text and selected nodes on a page?
- Javascript Highlight Selected Range Button
- Is there a function to deselect all text using JavaScript?
- Can I use the HTTP range header to load partial files “on purpose”?
- Does Internet Explorer 9 choke on extra commas at the end of array and object literals?
- Circles in Map Displayed Incorrect Location in D3 V4
- angularjs form reset error
- Implement async/await in sort function of arrays javascript