diff options
Diffstat (limited to 'phpBB')
-rw-r--r-- | phpBB/adm/style/editor.js | 2 | ||||
-rw-r--r-- | phpBB/styles/prosilver/template/editor.js | 2 | ||||
-rw-r--r-- | phpBB/styles/subsilver2/template/editor.js | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/phpBB/adm/style/editor.js b/phpBB/adm/style/editor.js index 217aa699e2..cad01aa9f2 100644 --- a/phpBB/adm/style/editor.js +++ b/phpBB/adm/style/editor.js @@ -292,7 +292,7 @@ function mozWrap(txtarea, open, close) */ function storeCaret(textEl) { - if (textEl.createTextRange) + if (textEl.createTextRange && document.selection) { textEl.caretPos = document.selection.createRange().duplicate(); } diff --git a/phpBB/styles/prosilver/template/editor.js b/phpBB/styles/prosilver/template/editor.js index c16b0ef703..42be70be92 100644 --- a/phpBB/styles/prosilver/template/editor.js +++ b/phpBB/styles/prosilver/template/editor.js @@ -347,7 +347,7 @@ function mozWrap(txtarea, open, close) */ function storeCaret(textEl) { - if (textEl.createTextRange) + if (textEl.createTextRange && document.selection) { textEl.caretPos = document.selection.createRange().duplicate(); } diff --git a/phpBB/styles/subsilver2/template/editor.js b/phpBB/styles/subsilver2/template/editor.js index 151cf53ff1..103a271a71 100644 --- a/phpBB/styles/subsilver2/template/editor.js +++ b/phpBB/styles/subsilver2/template/editor.js @@ -351,7 +351,7 @@ function mozWrap(txtarea, open, close) */ function storeCaret(textEl) { - if (textEl.createTextRange) + if (textEl.createTextRange && document.selection) { textEl.caretPos = document.selection.createRange().duplicate(); } |