onload event not firing in IE 9 and above.
$(document).ready(function(){
var popup = window.open('mypopup.html', 'bl', 'scrollbars=yes,location=no,toolbar=no,status=no,width=720,height=1000,left=300,top=50');
var htmlToPrint = $('#thank_view').clone();
htmlToPrint = htmlToPrint.html();
popup.onload =function(){
alert("ONLOAD WORKING");
$("#appended", popup.document).append( htmlToPrint );
}
});
I have also tried
$(popup).on("load", function(){
$("#appended", popup.document).append( htmlToPrint );
});
All the above methods work in all browsers except IE9 and above. Is there a way around this for newer IE browsers.