I have create one file field in my node create form , file is accepting (txt,pdf,xlx,docx) files only. but in node view page, i want to authenticate our file before download.

I have create one term and condition checkbox, if user check this term and condition checkbox , then he should be able to download the file..

This functionality i need to do, please suggest me any module is available for this..

or if this functionality is possible through conditional fields , so please suggest me, how can i do

  • 1
    Using Ajax you can do that, just make a ajax call once the authenticated user check the checkbox. Check the conditions and provide the download button.
    – Inizio
    May 13, 2014 at 6:25

1 Answer 1


You can try Field Permission Module

The Field Permissions module allows site administrators to set field-level permissions to edit, view and create fields on any entity.

Demo Video

  • 2
    Also, if file is stored in public filesystem, it will be publicly available even if field that refers it is not. So in addition to Field Permission module, storage should be set to private file system. Documentation here.
    – Mołot
    May 13, 2014 at 6:33
  • @Mołot Thanks for the pointer :) I think this will solve the problem, "making all the files private in the field settings and assigning Roles to download files using this module." drupal.org/project/private_files_download_permission
    – shrish
    May 13, 2014 at 6:42
  • If it works, sure, but it's "minimally maintained, maintenance fixes only" and has some old open bugs. Personally I think that Field Permissions to hide links to files, and private filesystem to protect linked files themselves, is the most stable combination.
    – Mołot
    May 13, 2014 at 6:47
  • no i am not talking about, file is private or public, my question is , i want to create this:- before download file, check one checkbox for user, i need to create this.... without click checkbox.. he should not be download file May 13, 2014 at 6:50
  • @SachinTonte well in that case Did you try this module, it seems work as you said. drupal.org/project/field_conditional_state
    – shrish
    May 13, 2014 at 6:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.