You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When user selects character 'e', some times the extractContents method only returns innerHTML 'e', not<span onmouseup="top.onMouseUpEssence('534','');" name="534">e</span>
Here is my code:
var selection = window.getSelection();
var range = selection.getRangeAt(0);
var container = document.createElement("span");
var selectionContents = range.extractContents();
container.appendChild(selectionContents);
Does any one know why? Thanks. I tested Firefox, it's sometimes working, for chrome, it's not working at all when only one character is selected.
The text was updated successfully, but these errors were encountered:
I have some text for user to select, like:
When user selects character 'e', some times the extractContents method only returns innerHTML 'e', not
<span onmouseup="top.onMouseUpEssence('534','');" name="534">e</span>
Here is my code:
Does any one know why? Thanks. I tested Firefox, it's sometimes working, for chrome, it's not working at all when only one character is selected.
The text was updated successfully, but these errors were encountered: