Originally Posted by Old Pedant
And if you don't care about MSIE 7, it can be even simpler:
// use AJAX to start creation of the new PDF
var http = new XMLHttpRequest();
// ignore the asynch response
// then just change the current popup to the new location:
location.href = "index.php?module=Patient_Procedure&action=genMFGPO&pomode=preview";
Cool. Yeah, this might work even better. It's an in-house app, and we're moving to IE 9, so no need to code for IE 7.
Quick question, that script that builds the PDF takes a couple of seconds to run. Is there something that I could do so that after the user clicks on the button, they don't click on it again until the whole process runs? I wonder if that's why the window.close was put in.