jQuery.printElement icon indicating copy to clipboard operation
jQuery.printElement copied to clipboard

Selected radio buttons in IE not printing correctly

Open gharris388 opened this issue 7 years ago • 0 comments

We have a long questionnaire in our application that contains a series of radio buttons. When the user prints the document from FF, the selected radio buttons appear correctly. In IE, the selections are lost.

We are using IE 10. In IE 7 and 8, the selected radio buttons appeared correctly.

To solve the issue, the following snippet of code in the _getElementHTMLIncludingFormElements method had to be changed.

-original code

//Radiobuttons and checkboxes $(":checked", $element).each(function () { this.setAttribute('checked', 'checked'); });

was changed to

$(":checked", $element).each(function (j) { $(this).prop('checked', 'checked'); });

We found that everything was okay with the radio elements up until the html() method was called. The checked property was still present after the clone method was called but it was lost once the html() method was executed.

gharris388 avatar Aug 11 '17 15:08 gharris388