Jump to content

Secure PDF files (only for users)


DV-JF
 Share

Recommended Posts

Hi,

I've created a frontend login form and redirect to a site where I want to offer some PDFs for registered users. I uploaded the files to a fields called pdf_files und looped through them to show them on the site. No Problem so far, BUT:

The direct URLs to the PDFs are public reachable.

Is there a way to solve this problem?

Many, greets, DV-JF alias, Jens.

Link to comment
Share on other sites

If the template where the pdf's are stored is not viewable by the guest role, then you can set $config->pageFileSecure to true. Then only roles that have view permission to the template are able to access the files directly.

  • Like 5
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...