diff options
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/partials/scripts-front.html | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/layouts/partials/scripts-front.html b/layouts/partials/scripts-front.html index c516aad..6b4d78b 100644 --- a/layouts/partials/scripts-front.html +++ b/layouts/partials/scripts-front.html @@ -13,16 +13,15 @@ </script> <script data-cfasync="false"> // ie detection - var ua = window.navigator.userAgent; - - function browserDetection() { - if (ua.indexOf('MSIE ') > 0 || ua.indexOf('Trident/') > 0 || ua.indexOf('Edge/') > 0) { + function browserDetection(ua) { + if (ua.indexOf('MSIE ') > 0 || ua.indexOf('Trident/') > 0) { return true; } return false; } - if (browserDetection()) { + var ua = window.navigator.userAgent; + if (browserDetection(ua)) { window.location.href('{{ "/ie/" | absURL }}'); } </script>
\ No newline at end of file |