diff --git a/phpBB/assets/javascript/editor.js b/phpBB/assets/javascript/editor.js index be3d868f13..dfc7dab525 100644 --- a/phpBB/assets/javascript/editor.js +++ b/phpBB/assets/javascript/editor.js @@ -288,7 +288,7 @@ function mozWrap(txtarea, open, close) { * http://www.faqts.com/knowledge_base/view.phtml/aid/1052/fid/130 */ function storeCaret(textEl) { - if (textEl.createTextRange) { + if (textEl.createTextRange && document.selection) { textEl.caretPos = document.selection.createRange().duplicate(); } }