Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#7670 closed bug (wontfix)

IE6 crashing when using window.location.reload for callback

Reported by: glipman Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.dialog Version: 1.8.14
Keywords: Cc:
Blocked by: Blocking:

Description

Within our complex application we use modal dialogs. Sometimes we provide windows.location.reload as callback to refresh the page after closing.

With IE6 and jQuery UI 1.7.2 this has worked fine for two years Recently we upgraded to UI 1.8.14 and now IE6 crashes

Crash IE6 with 1.8.14: http://jsfiddle.net/2Gn4w/10/

No problem with 1.7.2: http://jsfiddle.net/2Gn4w/7/

Note: it seems the crash occurs even before windows.location.reload is being called, just passing it in is causing the problem.

I do have a workaround: http://jsfiddle.net/2Gn4w/10/

function myreload() { windows.location.reload() }

and passing myreload does not crash.

But why is it crashing with 1.8.14 and not with 1.7.2?

Change History (4)

comment:1 Changed 8 years ago by glipman

Oops: the workaround url should be http://jsfiddle.net/2Gn4w/11/

comment:2 Changed 8 years ago by Scott González

Resolution: wontfix
Status: newclosed

This happens because IE 6 won't let us iterate through window.location.reload, which is done in $.isPlainObject, which is done inside $.widget.extend. I'm not inclined to wrap the $.isPlainObject() call in a try/catch just for this one case.

comment:3 Changed 8 years ago by glipman

Just for the record: I doubt a try/catch would help against an application (iexplore.exe) crash.

comment:4 Changed 8 years ago by Scott González

Good point, we'd have to avoid using $.isPlainObject() and do our own checks.

Note: See TracTickets for help on using tickets.