I want to save the webpage as pdf, the webpage is using javascript to create canvas element. In PDF the page looks more or less like a text version of the html page. Somehow the PDFs that are generated are shown without this canvas element. For information: I am using jquery.easypiechart library to create canvas element on the webpage, and tried tcpdf (in 7.1 version)and mpdf(with 7.2 version).
When in chrome I try to print pdf of the page it does display this canvas element correctly. How can I do the same with this module.
For reference I am attaching the two files.
I want that "From Print module.pdf" to look like "from Chrome.pdf".

Any help will be appreciated.

Thanks,
P.

CommentFileSizeAuthor
from Chrome.pdf55.64 KBprabhatjn
From Print Module.pdf45.35 KBprabhatjn

Comments

prabhatjn’s picture

Anyone??

jcnventura’s picture

Status: Active » Closed (works as designed)

TCPDF supports very little Javascript.

It certainly can't handle jQuery basic, even less any of it's plugins. You need to use wkthmltopdf for that, as that's the only PDF library that handles Javascript.