2

Am trying to add some png image to my print page with jquery, but am not able to do that, any help would be appreciated. Chrome version:Version 70.0.3538.102. My code: Here am appending all my image to "myImages" div and then printing.

setTimeout(function () {
    w=window.open();
    w.document.write($('#myImages').html());
    w.print();
    w.close();
}, 100);
A_S
  • 127
  • 7

1 Answers1

1

it work for me when i change this:

setTimeout(function () {
   w=window.open();
   w.document.write($('#myImages').html());
   w.print();
   w.close();
}, 100);

to this:

w=window.open();
w.document.write($('#myImages').html());
setTimeout(function () {
   w.print();
   w.close();
}, 100);
A_S
  • 127
  • 7