JavaScript: Remove current mouse highlight from the page?

I've understood the question a bit differently. I believe you want to know how to delete the selected text from the document, in which case you could use.

I've understood the question a bit differently. I believe you want to know how to delete the selected text from the document, in which case you could use: function deleteSelection() { if (window. GetSelection) { // Mozilla var selection = window.getSelection(); if (selection.

RangeCount > 0) { window.getSelection(). DeleteFromDocument(); window.getSelection().removeAllRanges(); } } else if (document. Selection) { // Internet Explorer var ranges = document.selection.

CreateRangeCollection(); for (var I = 0; I GetSelection) { window.getSelection().removeAllRanges(); } else if (document. Selection) { document.selection.empty(); } }.

Actually I want to remove the displayed highlight itself. – thedp Nov 17 '09 at 23:18 Thank you so much :) – thedp Nov 18 '09 at 20:23.

IE 4 and old Netscape used to have a method to do just this... It's not longer proper (nor supported). Your best guess would be to use Javascript to focus() on an object, and then blur() as well -- effectively like clicking away from the object. Document.

GetElementById("someObject").focus(); document. GetElementById("someObject").blur().

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions