Forum
00:47
21/06/2010
Moderator, I have moved this from the 'Help' forum. Please delete that post titled "Default Filter(s) fail in IE7; Work great in FireFox"
I need help understanding why the code below works great in FireFox 3.6.3, but fails in IE7 & IE6.
jQuery Grid versions tested: 3.6.5 (using jQuery 1.3.2) and 3.7.1 (using jQuery 1.4.2).
I would greatly appreciate any help.
IE7 & 6 Error message:
Do you wish to Debug?
Line: 569
Error:'find(…).0' is null or not an object
**The line number reported by IE7 corresponds to the setFilter function in jquery.searchfilter.js
Code:
var mygrid = jQuery("#speed").jqGrid({
url:'get_some_data.php',
datatype: "JSON",
height: 140,
width: 950,
colNames:['User ID','Last Name', 'First name', "Phone", "Email"],
colModel:[
{name:'uid',index:'uid', width:65},
{name:'lname',index:'lname', width:65},
{name:'fname',index:'fname', width:65},
{name:'phone',index:'phone', width:65},
{name:'email',index:'email', width:65}
],
rowNum:6,
rowList:[10,20,30],
mtype: "POST",
rownumbers: false,
rownumWidth: 40,
gridview: true,
pager: '#speedp',
sortname: 'uid',
viewrecords: true,
sortorder: "asc",
hidegrid: false,
caption: "All Users",
search:true,
postData: {
"filters":'{"groupOp":"and","rules":[{"field":"uid","op":"eq","data":"100"}, {"field":"lname","op":"eq","data":"test"}]}'
}
});
mygrid.navGrid('#speedp', {edit:false,add:false,del:false,search:true,refresh:false, searchtext:"Search" },
{},{}, {}, {multipleSearch:true} );
11:57
Moderators
30/10/2007
Hello,
Please search this forum, thare are a lot of post about this problem and how to resolve in IE
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
19:17
21/06/2010
Hi Tony,
I searched before I posted, and I searched again after you responded. The solutions to the problems other users have had with IE -- in the posts that I looked at -- don't apply or don't work for my problem. Can you point me to a post where users have issues with IE and default filters?
More information:
To be more specific about the problem. When I click on the search button once, I get the error in my first post. When I click a second time, immediately after, the multiple search dialog comes up with only the first search row populated. It fails to populate the second search row.
Here's the HTML:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>jqGrid Demos</title>
<link rel="stylesheet" type="text/css" media="screen" href="themes/custom-theme/jquery-ui-1.7.2.custom.css" />
<link rel="stylesheet" type="text/css" media="screen" href="themes/ui.jqgrid.css" />
<script src="jquery.jqGrid-3.7.1/js/jquery-1.4.2.min.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/js/i18n/grid.locale-en.js" type="text/javascript"></script>
<script src="js/jquery-ui-1.7.1.custom.min.js" type="text/javascript"></script>
<script src="js/jquery.layout.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/js/jquery.jqGrid.min.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/src/grid.common.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/src/grid.postext.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/src/grid.formedit.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/src/jquery.searchFilter.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/src/jquery.fmatter.js" type="text/javascript"></script>
<script src="jquery.jqGrid-3.7.1/src/JsonXml.js" type="text/javascript"></script>
</head>
<body>
<table id="speed" class="scroll" cellpadding="0" cellspacing="0"></table>
<div id="speedp" class="scroll" style="text-align:center;"></div>
<div id="speed_div"></div>
<script src="mytest.js" type="text/javascript"></script>
</body>
</html>
23:22
21/06/2010
Update
Even when I remove the following lines from the .js file, the multiple search feature generates an error when I select 'reset' after adding more than one search criteria.
Removed lines:
postData: {"filters":{"groupOp":"and","rules":[{"field":"uid","op":"eq","data":"100"},{"field":"lname","op":"eq","data":"test"}]}}
Error generated when 'reset' is selected after adding more than one search criteria
Do you wish to Debug?
Line: 569
Error:'find(…).0' is null or not an object
postData: {"filters":{"groupOp":"and","rules":[{"field":"uid","op":"eq","data":"100"},{"field":"lname","op":"eq","data":"test"}]}}*/
11:08
Moderators
30/10/2007
Hello,
Could you please read this?
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
18:17
21/06/2010
Hi Tony,
I already have a DOCTYPE declaration -- look at HTML above. It fails even after using the DOCTYPE that you provide in the post you link to.
About the Apache META tag solution, is this the only way? What if I don't have rights to modify the Apache httpd.conf file?
On my localhost, adding "Header set X-UA-Compatible “IE=EmulateIE7”" under "LoadModule headers_module modules/mod_headers.so" and restarting Apache doesn't change anything. The second filters 'op' value is still coming through as undefined.
Thank you for all your help so far.
14:30
Moderators
30/10/2007
Hello,
I really want to know where is the problem. Can you please prive a link to the problem?
Thank you
Best Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
Most Users Ever Online: 715
Currently Online:
28 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66