Closed EricG-Personal closed 6 years ago
Seems to me that it is not a jspdf-problem. It is more a Browser-behaviour thing...
By setting the src-attribute of the iframe results in opening the pdf by e.g. Acrobat Reader results in not parsing it by the DOM. Thus results that the print-Method is not working.
https://stackoverflow.com/questions/18835648/print-pdf-from-javascript-embed-tag
Use instead autoprint plugin...
doc.autoPrint();
Closed issue. If you have further questions, we will reopen.
I have some sample code located on a branch for jspdf - https://github.com/EricG-Personal/pdf_printing/tree/feature/from_jspdf
I am doing the following to generate the PDF.
The PDF data renders correctly in the iframe and I end up calling:
when the onLoad function of the iframe triggers.
However, the page that is to actually be printed is blank.