Problem with jqGrid in Internet Explorer 8
Posted
by Dave Swersky
on Stack Overflow
See other posts from Stack Overflow
or by Dave Swersky
Published on 2010-02-23T18:31:54Z
Indexed on
2010/04/02
13:13 UTC
Read the original article
Hit count: 1146
asp.net-mvc
|jqgrid
I have developed an ASP.NET MVC (version 2 RC) application with a ton of jqGrids. It's working like a champ in Firefox, but I've discovered a problem in IE8.
The "Main View" grids can be filtered by a search box or one of a few dropdowns above the grid. I use some javascript to reset the url for the grid, then trigger a reload, thusly:
function filterByName(filter) {
if (filter == 'All') {
$('#list').setGridParam({ url: 'Application/GetApplications' });
$('#list').trigger("reloadGrid");
}
else {
$('#list').setGridParam({ url: 'Application/GetAppByName/' + filter + '/' });
$('#list').trigger("reloadGrid");
}
}
This works like magic in Firefox, but I'm getting an HTTP 400 Bad Request when I do this in IE8. The IE8 client-side debugger is like flint and tinder compared to Firebug's flamethrower, so I'm not having much luck figuring out why it breaks in IE8. Has anyone seen this?
Also, the jqGrid "trigger" method here is swallowing the AJAX exception. Is there a way to get it to bubble up so I can get to the exception details?
UPDATE:
The problem was with the syntax in my "onchange" event for the dropdowns. I was using:
onchange="filterByMnemonic($('#drpMnemonic')[0].value);
Which Firefox apparently doesn't mind but IE sees that as nuthin'. This, however, works in both browsers:
onchange = "filterByMnemonic($('#drpMnemonic > option:selected').attr('value'));"
© Stack Overflow or respective owner