This project has moved. For the latest updates, please go here.
1
Vote

Error using IE 11 and IE edge

description

Does anyone are getting errors on method pasteHTML?
On IE 11 I got the error on line 171 (r.pasteHTML(html)) and it makes jHTMLArea impossible to use in IE 11.
At EDGE I got the error on line 180 (r.select()), in EDGE I can still keep using jHTMLArea.

Both erros I got using version 0.8.

Any patch for this error?

Thanks a lot.

comments

gmoricz wrote May 31, 2016 at 10:51 PM

For now, to solve the error in IE 11, I did it:

if (typeof r.select == 'function') {
            r.pasteHTML(html);
        }
        else
        {
            r.deleteContents();
            r.insertNode($(this.iframe[0].contentWindow.document.createElement("span")).append($((html.indexOf("<") != 0) ? "<span>" + html + "</span>" : html))[0]);
        }