call this function on click of the link, from where you download the pdf file.
This would still allow for downloading without password, just by looking at the page source.
Another way would be to put the pdf in a separate folder on the server, and password protect it (using your cPanel, htaccess, or whatever you're using).
Reputation Points: 550
Solved Threads: 731
Bite my shiny metal ass!
Offline 4,177 posts
since Jul 2006