mirror of
				https://github.com/ether/etherpad-lite.git
				synced 2025-10-31 08:11:10 +01:00 
			
		
		
		
	Merge pull request #1192 from marcelklehr/fix/l10n-ie-bug
Fix #1186 Autodetection wouldn't work correctly in IE9
This commit is contained in:
		
						commit
						4fb46c0063
					
				| @ -902,7 +902,7 @@ document.webL10n = (function(window, document, undefined) { | ||||
|   // browser-specific startup
 | ||||
|   if (document.addEventListener) { // modern browsers and IE9+
 | ||||
|     document.addEventListener('DOMContentLoaded', function() { | ||||
|       var lang = document.documentElement.lang || navigator.language; | ||||
|       var lang = document.documentElement.lang || navigator.language || navigator.userLanguage || 'en'; | ||||
|       loadLocale(lang, translateFragment); | ||||
|     }, false); | ||||
|   } else if (window.attachEvent) { // IE8 and before (= oldIE)
 | ||||
| @ -977,7 +977,7 @@ document.webL10n = (function(window, document, undefined) { | ||||
|     // startup for IE<9
 | ||||
|     window.attachEvent('onload', function() { | ||||
|       gTextProp = document.body.textContent ? 'textContent' : 'innerText'; | ||||
|       var lang = document.documentElement.lang || window.navigator.userLanguage; | ||||
|       var lang = document.documentElement.lang || navigator.language || navigator.userLanguage || 'en'; | ||||
|       loadLocale(lang, translateFragment); | ||||
|     }); | ||||
|   } | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user