Print to Google Cloud Print with dynamic URL
I'd like a "print" button on my web-site to print a document with Google Cloud Print, but I want the "url" of the target – a PDF file – to change dynamically, after the button has been clicked (notably, based on what's returned from an AJAX call). The GCP Web Element (GCPWE) seems to have similar functionality, but not quite what I desire. In particular, it seems as though one can only change the "target" (by calling setPrintDocument ) before the button is clicked. Is there a way to specify the URL for GCPWE after the button has been clicked? Here's the example code from the GCPWE site: <div