I'm using JSF 2.2 and Primefaces 5.1
I'm trying to take a "screenshot" of my website using html2canvas, then send it to my back-end to generate a PDF report so the user can download it. The problem is I will occasionally get an ajax error, on Firebug it shows an XHR with no status code, no response, 0 Bytes in size. The download STILL WORKS perfectly, but I get this annoying ajax error that gets picked up by my global ajaxStatus and I have to reload the page.
This is what it looks like on Firebug
This is how I'm doing it with html2canvas.
Onclick event calls a javascript function
The Function
dataURLfield
clickPrintButton function
The hidden download button
Any clues? I've been stuck on this for weeks. Any help is appreciated.
I'm trying to take a "screenshot" of my website using html2canvas, then send it to my back-end to generate a PDF report so the user can download it. The problem is I will occasionally get an ajax error, on Firebug it shows an XHR with no status code, no response, 0 Bytes in size. The download STILL WORKS perfectly, but I get this annoying ajax error that gets picked up by my global ajaxStatus and I have to reload the page.
This is what it looks like on Firebug
This is how I'm doing it with html2canvas.
Onclick event calls a javascript function
The Function
dataURLfield
clickPrintButton function
The hidden download button
Any clues? I've been stuck on this for weeks. Any help is appreciated.