PageSourceSearch

https://www.unav.edu/o/unav-principal-theme/js/ie/ie-emulation-mod…=js&languageId=es_ES&t=1790832354000

js unav.edu collected 2026-10-01 10:12:36 UTC 2,148 bytes, 52 lines download raw bytes

1/*1790832618000*/
2// NOTICE!! DO NOT USE ANY OF THIS JAVASCRIPT
3// IT'S JUST JUNK FOR OUR DOCS!
4// ++++++++++++++++++++++++++++++++++++++++++
5/*!
6 * Copyright 2014-2015 Twitter, Inc.
7 *
8 * Licensed under the Creative Commons Attribution 3.0 Unported License. For
9 * details, see https://creativecommons.org/licenses/by/3.0/.
10 */
11// Intended to prevent false-positive bug reports about Bootstrap not working properly in old versions of IE due to folks testing using IE's unreliable emulation modes.
12(function () {
13  'use strict';
14
15  function emulatedIEMajorVersion() {
16    var groups = /MSIE ([0-9.]+)/.exec(window.navigator.userAgent)
17    if (groups === null) {
18      return null
19    }
20    var ieVersionNum = parseInt(groups[1], 10)
21    var ieMajorVersion = Math.floor(ieVersionNum)
22    return ieMajorVersion
23  }
24
25  function actualNonEmulatedIEMajorVersion() {
26    // Detects the actual version of IE in use, even if it's in an older-IE emulation mode.
27    // IE JavaScript conditional compilation docs: https://msdn.microsoft.com/library/121hztk3%28v=vs.94%29.aspx
28    // @cc_on docs: https://msdn.microsoft.com/library/8ka90k2e%28v=vs.94%29.aspx
29    var jscriptVersion = new Function('/*@cc_on return @_jscript_version; @*/')() // jshint ignore:line
30    if (jscriptVersion === undefined) {
31      return 11 // IE11+ not in emulation mode
32    }
33    if (jscriptVersion < 9) {
34      return 8 // IE8 (or lower; haven't tested on IE<8)
35    }
36    return jscriptVersion // IE9 or IE10 in any mode, or IE11 in non-IE11 mode
37  }
38
39  var ua = window.navigator.userAgent
40  if (ua.indexOf('Opera') > -1 || ua.indexOf('Presto') > -1) {
41    return // Opera, which might pretend to be IE
42  }
43  var emulated = emulatedIEMajorVersion()
44  if (emulated === null) {
45    return // Not IE
46  }
47  var nonEmulated = actualNonEmulatedIEMajorVersion()
48
49  if (emulated !== nonEmulated) {
50    window.alert('WARNING: You appear to be using IE' + nonEmulated + ' in IE' + emulated + ' emulation mode.\nIE emulation modes can behave significantly differently from ACTUAL older versions of IE.\nPLEASE DON\'T FILE BOOTSTRAP BUGS based on testing in IE emulation modes!')
51  }
52})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.