I have developed a page with ExtJS. It works in FF, Chrome and Opera but not in IE.
In IE I have this message :
Webpage error details
User Agent: Mozilla/4.0 (compatible;
MSIE 7.0; Windows NT 5.1; Trident/4.0)
Timestamp: Mon, 20 Jun 2011 15:51:23
UTCMessage: ‘locked’ is null or not an
object Line: 14364 Char: 13 Code: 0
URI:
http://192.168.240.129/lib/ext4/ext-all-debug.jsMessage: Exception thrown and not
caught Line: 25281 Char: 9 Code: 0
URI:
http://192.168.240.129/lib/ext4/ext-all-debug.js
I don’t know why it refers to ‘locked’. I don’t have a locked variable or other in my page.
Thanks if you have some idea or answer.
When working with ExtJs in IE you need to consider that the IE’s JSON parser is a lot stricter than that of Chrome or FF. Consider this JSON for instance:
It is perfectly valid for all mayor Browses so you will not get any error when using it, however notice the last coma on the last element, there is where the problem with IE begins. If you get the length of such object on Chrome/FF the value will be 5, while in IE it will be 6. This means that the parser in IE considers a 6th null element that is after the last coma. This is what is breaking your ExtJs.
A great way to clean up code to avoid the the extra commas is to validate your code using http://www.jslint.com/