Forums Register Login

Occasional Ajax error, no status code, no response

+Pie Number of slices to send: Send
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.
Willie Smits can speak 40 languages. This tiny ad can speak only one:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 1616 times.
Similar Threads
p:fileDownload not working with h:head
JSF AJAX rerenders outputText component but EL value ends up stale in javascript function
JSF, how to throw ajax error in ajax handler
apache.commons.fileupload - Browser blocks ajax requests
how to use selectOneRadio with javascript?
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 23:17:05.