[BUGFIX] RTE is not loading in IE8, when used with feedit
authorStefan Aebischer <typo3@pixtron.ch>
Mon, 3 Sep 2012 12:50:30 +0000 (13:50 +0100)
committerStanislas Rolland <typo3@sjbr.ca>
Tue, 9 Oct 2012 20:21:42 +0000 (22:21 +0200)
Solution: Avoid calls to undefined console methods

Change-Id: I1c2b72113a6a0045996ca5a219cd0bd49f6a0ae8
Fixes: #40558
Releases: 6.0, 4.7, 4.6
Reviewed-on: http://review.typo3.org/14311
Reviewed-by: Stanislas Rolland
Tested-by: Stanislas Rolland
typo3/sysext/rtehtmlarea/htmlarea/htmlarea.js

index da714e4..7ace023 100644 (file)
@@ -136,12 +136,13 @@ Ext.apply(HTMLArea, {
                        var type = 'info';
                }
                if (typeof(console) !== 'undefined' && typeof(console) === 'object') {
-                               // If console is TYPO3.Backend.DebugConsole, write only error messages
+                       // If console is TYPO3.Backend.DebugConsole, write only error messages
                        if (Ext.isFunction(console.addTab)) {
                                if (type === 'error') {
                                        console[type](str);
                                }
-                       } else {
+                       // IE may not have any console
+                       } else if (typeof(console[type]) !== 'undefined') {
                                console[type](str);
                        }
                }