Can you redirect a page AFTER you force a PDF download (Using a PHP script)?
I have a website where I offer a free PDF download without requiring an opt-in. You just click on the download button and, instead of just letting the PDF open in your browser, I'm using the following PHP code to "force" you to see the "Save As..." dialog box instead:
<?php
header('Content-disposition: attachment; filename=the-sticky-note-report.pdf');
header('Content-type: application/pdf');
readfile('the-sticky-note-report.pdf');
$URL="http://www.thestickynotereport.com/thank-you.html";
header ("Location: $URL");
To be honest, my knowledge of PHP is limited mostly to monkey see-monkey do, so maybe it isn't even possible to force the download AND redirect the page as well...or is it? Does anyone know (and, if so, how is it done?)
(If you need to see the page in action, it's the first link in my sig.)
Thanks for any help or ideas!
Regards,
Tommy.
http://graphicriver.net/user/723media/portfolio
Are you ready to finally launch your product?