I wrote a function to highlight a text which is selected using following method,
$('.highlight').click(function(){
document.execCommand("insertHTML", false, "<span style=background-color:yellow;>"+ document.getSelection()+"</span>");
});
but, now i needs to unhighlight the selected text, could you please help me.
Thanks in advance.