uploaded form files permissions

John Minorini asked on November 17, 2016 22:18

we have a form with a file upload control on it. When a form is submitted an admin gets a notification email with a link to the file that was uploaded. If the admin clicks on the link to the file, and is already logged into the site admin, the file loads fine. If the admin is not logged into the site they get a blank screen.

How can we set up the file permissions so a user does not need to be signed into the site to view the file if they have a direct link to it. Giving "non authenticated users" read only permission to the forms module allows you to view the file if you are not logged in. However, giving this type of public access to the module does not seem correct, are there any other options?

Recent Answers


Trevor Fayas answered on November 18, 2016 00:21

I would create a custom page that handles that logic for you, either by getting the normal link to the file (if the file is stored in file systems), or if it's in the database, impersonate a "file access only" user and then continue them on to the main file.

So if the File is at A, your Custom page is at B, give the user a link to B which logs them in and redirects them to A.

Just one option.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.