html2canvas-proxy
html2canvas-proxy copied to clipboard
How do I use html2canvas proxy
Hey,
So in html2canvas.js i set
// preload options
proxy: 'proxy.js',
timeout: 0, // no timeout
useCORS: false, // try to load images as CORS (where available), before falling back to proxy
allowTaint: false, //
And in proxy.js (node.js proxy) What do I set here
var url, http, request; url = require('url'); http = require('http'); request = require('request');
I am running on my local host and I am using html2canvas to capture cross-domain homepage screenshots.
I keep getting this error
html2canvas.js:359 2 Blocked a frame with origin "http://localhost" from accessing a frame with origin "http://money.rediff.com". Protocols, domains, and ports must match. html2canvas.js:359 Uncaught ReferenceError: require is not defined proxy.js:10 (anonymous function)
Please help.
Did you found a solution because I'm having the same question.