Questions tagged [html2canvas]

html2canvas is a JavaScript HTML-rendering library that lets you take "screenshots" of webpages based on the DOM.

From the official site:

This script allows you to take "screenshots" of webpages or parts of it, directly on the users browser. The screenshot is based on the DOM and as such may not be 100% accurate to the real representation as it does not make an actual screenshot, but builds the screenshot based on the information available on the page.

1794 questions
8
votes
3 answers

Hide object in canvas

I want to know that, Is it possible to hide text object in canvas using fabric js? I don't want to remove object, as I need it in further use, so just want to hide it. I searched a lot, but didn't work anything. Here is my code of fabric js. var…
Trusha Savsani
  • 489
  • 1
  • 11
  • 31
8
votes
1 answer

Using html2canvas to render a highcharts chart to pdf doesn't work on IE and Firefox

We are using html2canvas.js and html2canvas.svg.js (version 0.5.0 beta1) and highcharts.js to download a donut chart into pdf. This works as expected in Chrome, however in IE and Firefox this isnt working. In IE the chart is rendered incorrectly,…
Rob
  • 1,407
  • 2
  • 15
  • 22
8
votes
3 answers

Three.js Screenshot

I need to make screenshot of website. I tried using html2canvas and all and it's working. But problem is i'm using THREE.WebGLRenderer and THREE.CSS3DRenderer (for html in webgl)... So when I make screenshot it makes images only from WebGLRenderer.…
Klemenko
  • 704
  • 1
  • 10
  • 21
8
votes
2 answers

HTML String in Html2Canvas

How do we pass a valid HTML String into html2canvas? e.g var html = "

HI

The way it is done on http://html2canvas.hertzen.com/screenshots.html Html2canvas is really great and all but it's very poorly…
Manak Kapoor
  • 962
  • 3
  • 12
  • 21
7
votes
1 answer

How to use html2canvas proxy

I'm using html2canvas plugin to generate snapshot of web pages. The problem is that everything runs ok in the localhost, however when deployed on the remote server I get the following error : Unable to get image data from canvas because the canvas…
amine
  • 181
  • 1
  • 2
  • 9
7
votes
5 answers

Get all elements containing a class with querySelector

For changing some styles in a class I'm using querySelector(): el.querySelector('.fa fa-car').style.display = "none"; This works fine for one element but if there are more elements containing this class and I want to change the display to none for…
Leo Messi
  • 5,157
  • 14
  • 63
  • 125
7
votes
3 answers

PDF does not show images : html2pdf library

I use Angular 5 and html2pdf library which helps create pdf file. https://github.com/eKoopmans/html2pdf this is used for my Angular method. var element = document.getElementById('document'); var opt = { margin: [10, 0, 10, 0], …
CHRIS LEE
  • 776
  • 3
  • 10
  • 20
7
votes
0 answers

html2canvas is not working in Ipad/iPhone iOS 11.2.1 Safari borwser

I have use html2canvas function for capturing screen shot from div its working fine on web but its not working in Ipad iOS 11.2.1 Safari browser getting blank response. I have using Ipadair2 with iOS 11.2.1 Include JS Version: jQuery v1.7.1…
7
votes
2 answers

Using jspdf to save html page as pdf, saved pdf contains incomplete page content if browser is zoomed, Why?

I am using jspdf and html2canvas combination to save html page as pdf. A pdf copy of current page is saved the moment you click a button. The problem is, if you zoom in the page, and then click the button, the saved pdf contains incomplete portion…
shanti
  • 270
  • 1
  • 4
  • 20
7
votes
3 answers

How to cut an image / HTML canvas in half via javascript?

I'm using html2canvas to turn a google map javascript API with custom features, into a canvas, and then an image. Works fine on all browsers, except on IE 11 it generates an image with extra blank space to the right of the image, equal to the (width…
TetraDev
  • 16,074
  • 6
  • 60
  • 61
7
votes
1 answer

Html2canvas: facebook plugin comments

I have a website witch uses facebook plugin comments. I'm looking for a way to have those comments inside a screenshot. If I use the simple html2canvas I get a blank box instead of them. So I try to use html2canvasproxy but now it print some…
user1315621
  • 3,044
  • 9
  • 42
  • 86
7
votes
3 answers

Scale image before toDataURL - html2canvas

Before you tell me this is a duplicate question, know that I've searched through every single similar question and none of the answers in any of them are working for me. Im using html2canvas to grab a snapshot of a div, and what I need to do is…
shaneparsons
  • 1,489
  • 1
  • 20
  • 24
7
votes
6 answers

Html2Canvas Resize

I am using html2canvas in an effort to get a screenshot of a webpage and render it as a thumbnail (well, 400x300, not exactly a thumbnail). Based on the Screenshot console code, everything works great with the exception of the thumbnail part. How…
Chris
  • 18,075
  • 15
  • 59
  • 77
6
votes
1 answer

How to download customisable color change box as image with the background image?

I have a box that can change color once you select the box and then select the color. However, there is also a background image that shows the outline of the box. I have used HTML2canvas and jquery as libraries so I can download the customise color…
user8
  • 168
  • 10
6
votes
1 answer

Missing images depending on scale in html2canvas (html2pdf)

I am trying to make a PDF of a reasonable amount of text and graphs in my html using html2pdf. So far so good, the PDF gets made and it looks fine. It is about 20 pages. However, multiple graphs are missing. Some relevant information: Most of the…
Century
  • 283
  • 1
  • 4
  • 22