Generate screenshot

Hi everyone,

I try to capture a screenshot of my current page. This is what I did :

  1. To activate html2canvas, I added the following script of html2canevas to my page header :
    src=“https://cdnjs.cloudflare.com/ajax/libs/html2canvas/0.4.1/html2canvas.min.js”>

  2. I created an element (image) in my page and genrate and ID for this element.

  3. I run this Javascript code into the trigger workflow :

var element = document.getElementById(‘MY_IMAGE_ID’);

html2canvas(document.body).then(function(canvas) {

element.src = canvas.toDataURL();
});

I stilll cannot capture the screenshot in my element. Do you have any idea of what I did wrong ? Or any other suggestion will be more than welcome.

Thanks,

This topic was automatically closed after 70 days. New replies are no longer allowed.