Can any one help with this .
Case 1: Print in same window.
var restorepage = $('body').html();
var printcontent =
$('#ctl00_WebPartManager_BlankWP0_CanvasControl_Canvas').clone();
$('body').empty().html(printcontent);
window.print();
$('body').html(restorepage);
Output: This is perfect for me , the only thing is after i restore the original controls they dont seem to work . So I am trying to print the same using a new window.
Case 2: Print in a New window
var w = window.open();
var printcontent = $('#ctl00_WebPartManager_BlankWP0_CanvasControl_Canvas').clone();
$(w.document.body).empty().html(printcontent);
w.focus();
w.print();
w.close();
Output : The Images are realigned and even image goes missing. I need the Case1 Output , but in a new window , so as the original window is not modified.