Opened 14 years ago

Closed 12 years ago

Last modified 12 years ago

#4589 closed bug (fixed)

Modal dialog not retaining radio button selection

Reported by: kharpoh Owned by:
Priority: major Milestone: 1.8.6
Component: ui.dialog Version: 1.7.2
Keywords: Cc:
Blocked by: Blocking:

Description

Steps to reproduce.

1) Open dialog 2) Make any radio selection 3) Close dialog 4) Re-open dialog (Radio selection is missing)

It works for checkboxes.

Attachments (1)

dialog_issue.html (4.6 KB) - added by kharpoh 14 years ago.

Download all attachments as: .zip

Change History (9)

Changed 14 years ago by kharpoh

Attachment: dialog_issue.html added

comment:1 Changed 14 years ago by kharpoh

This is only an issue with IE.

comment:2 Changed 14 years ago by Jörn Zaefferer

Milestone: TBD1.8

comment:3 Changed 14 years ago by Jörn Zaefferer

Priority: criticalmajor

Doesn't seem to be related to DOM manipulations, at least there doesn't seem to happen any DOM element movements.

Considering this affects just radiobuttons in IE, it should be easy enough to implement a workaround (store the state before close, restore it on open).

comment:4 Changed 14 years ago by Jörn Zaefferer

Though about checkboxes, but likely related: http://channel9.msdn.com/wiki/wiki/InternetExplorerProgrammingBugs/ (search for "checkbox" to get to the right section)

comment:5 in reply to:  description Changed 13 years ago by watanabe

See:
jQuery UI 1.8.1 uncompressed version.
jquery.ui.dialog.js
line 279(dialog open)

uiDialog.appendTo('body');

In IE6, "append" resets radio button selection.
Test Code:

$("#testButton").click(function () {
 $("#radioButtonsContainer").appendTo("body");
});

But I don't know what the line 279 means.

line 278

if (uiDialog.next().length) {

...Making uiDialog the last child of body to moveToTop?

But in line 284

self.moveToTop(true);

...Appending uiDialog to the DOM-Tree?

But in line 60(dialog _create)

.appendTo(document.body)

...already appended?

comment:6 in reply to:  description Changed 13 years ago by watanabe

See Ticket #4534, Ticket #3012.

comment:7 Changed 12 years ago by Scott González

Resolution: fixed
Status: newclosed

Fixed in e66cdfc.

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

Milestone: 1.91.8.6
Note: See TracTickets for help on using tickets.