Firstly, thanks this awesome tool helping my day.
Here is a bug report, hopes it can help others.
In IE 8, the return object of $().getSelection().text is buggy.
I found out the reason.
The reason is the new-line symbol in IE8 is \r\n and IE11 or FF or Chrome is \n
This makes setSelection() and getSelection() buggy.
/*
<textarea id="area"> a
b</textarea>
*/
$("#area").setSelection(1,3);
$("#area").getSelection();
Thanks.
Firstly, thanks this awesome tool helping my day.
Here is a bug report, hopes it can help others.
In IE 8, the return object of
$().getSelection().textis buggy.I found out the reason.
The reason is the new-line symbol in IE8 is
\r\nand IE11 or FF or Chrome is\nThis makes
setSelection()andgetSelection()buggy.Thanks.