1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 22:10:45 +02:00

[ticket/14163] Properly fix select all for code tag in Edge

PHPBB3-14163
This commit is contained in:
Marc Alexander
2015-09-15 14:42:11 +02:00
parent 2bf9e91101
commit 3cdf97f003

View File

@@ -159,7 +159,10 @@ function selectCode(a) {
try {
s.setBaseAndExtent(e, 0, e, l);
} catch (error) {
s.setBaseAndExtent(e, 0, e, 1);
r = document.createRange();
r.selectNodeContents(e);
s.removeAllRanges();
s.addRange(r);
}
}
// Firefox and Opera