-
8 Nov 2012 6:31 PM #1
Answered: Ext.application works in all browsers except IE9
Answered: Ext.application works in all browsers except IE9
Hi,
I have a MVC Ext.application that works in Chrome, Firefox, Safari etc, but won't load in Internet Explorer 9. Though if a enable Developer Tools (F12) it will load. Any idea why this is happening? Or suggestions on how to debug what is happening?
Regards,
Tim
-
Best Answer Posted by devnullable
Sounds like you have console.log() call(s) somewhere? Those will fail if Developer Tools is not active.
If that is the reason you can add following to your app.js to comfort IE:
Code:if (!window.console) window.console = {}; if (!window.console.log) window.console.log = function () { };
-
8 Nov 2012 6:55 PM #2Sencha - Ext JS Dev Team
- Join Date
- Apr 2007
- Location
- Sydney, Australia
- Posts
- 15,103
- Vote Rating
- 97
- Answers
- 171
First thing to do would be to check for trailing commas.
Code:Ext.define('Foo', { foo: function(){ }, bar: function(){ }, });Evan Trimboli
Sencha Developer
Twitter - @evantrimboli
Don't be afraid of the source code!
-
8 Nov 2012 7:06 PM #3
Hi Evan,
That doesn't appear to be the problem.
A very simple app that doesn't work:
Code:<!doctype html> <html> <head> <meta charset="UTF-8"> <title>AS3 to JS/Sencha Migration</title> <link rel="stylesheet" type="text/css" href="extjs/resources/css/ext-all.css"> <script type="text/javascript" src="extjs/ext-all-dev.js"></script> <script type="text/javascript" src="app.js"></script> </head> </html>Regards,Code:Ext.onReady(function() { var button = Ext.create("Ext.Button", { text:"Click me", renderTo: Ext.getBody() }); button.addListener( "click", function(e) { this.setText("Clicked"); }); });
Tim
-
8 Nov 2012 8:16 PM #4
Sounds like you have console.log() call(s) somewhere? Those will fail if Developer Tools is not active.
If that is the reason you can add following to your app.js to comfort IE:
Code:if (!window.console) window.console = {}; if (!window.console.log) window.console.log = function () { };
-
8 Nov 2012 8:47 PM #5
That's done it. Thank you very much.



Reply With Quote