Skip to content
Advertisement

Tag: html2canvas

How can I combine multiple images into one page and print it as a pdf?

I’ve a webpage with 4 charts. I’m taking separate screenshots for each of them. Then tried to put them on another canvas, show them vertically and print it as single-page pdf file. But, I’m getting an Error saying: Uncaught TypeError: CanvasRenderingContext2D.drawImage: Argument 1 could not be converted to any of: HTMLImageElement, SVGImageElement, HTMLCanvasElement, HTMLVideoElement, ImageBitmap. Here is the script Answer

html2canvas not capturing image

html2canvas.js not capturing image. it leaves white space where the image occurs. I have tried a lot but i cannot find solution . Help is appreciated 🙂 Answer It works, when I host it in the server. The security restrictions causes it to fail.

Advertisement