Password protecting a file
Автор: Jyri Y.Hi
I have a password protected area on my website which mainly contains links to my .pdf files.
The .pdf files are in files folder (I used the "Files linked to HTML code"). I would like to be able to link the direct .pdf files to my users and the website would then ask for username and password. Now when I do it does not ask for then since the path is "myserver.xxx/files/file.pdf" and the password protection has nothing to do with this file or folder.
Is there any way I can tell the program to ask for username and password since it already should know that the files are linked in a password protected area and should not be viewable to the public. Some of my users might give these links to unathorized people and I don't want that..
I stopped using .htaccess files, when I bought the program since this way is much easier, but if this is something that can't be fixed then I might have to downgrade.
Thanks
I recently created an example of how to solve this.The test page can be seen here.
http://testseiten.unofficialwsx5.de/direkt_aufruf/
The pages are in German but I think one can recognize and use google translate to find your way around.
If you want I can even make the project as a whole is available.
Автор
That is exactly what I want, I didn't understand how you did that?
Please upload the project if you can, thank you very much!
See forum
http://unofficialwsx5.de
You have to register then you see the topic with attachement. The file is too large to upload here.
Автор
Way too hard for me. I tried... Chrome tries to download the .pdf (I want to display it on the screen) and the .pdf files are for some reason corrupted.
Thank you for your time and effort
Some one else has an idea?
I must update the script
You can also save a pdf file with a password (PDF with password protection).