Uploading Files via Forms

You can use forms to allow a user to upload images and/or documents.  These can optionally be uploaded directly into Salesforce and associated either with Salesforce Libraries or Specific Records in Salesforce.   On the public site, a logged in user will be able to upload one or more files at a time.

If you've synched the uploaded files to Salesforce, the user will have future access to the files through this form, should they wish to delete or update a file they've uploaded.

If you do not synch the files directly to Salesforce, they will be available via links in the CMS via AddOns / Export Form Data - and the volunteers will not have access to the files they've uploaded.

How to configure a form to be saved in Salesforce

To save a file in relation to a contact, you must select "Required Login".   Choose the object you wish to associate the file with.  In this scenario I want the uploaded files to be related to the contact record, so we'll choose contact.   (You could however use ARS and associate a file with a connection, or with any other object)

Choose populate fields from Salesforce is you want the user to be able to access the files that they've uploaded.  

Banners and Alerts

Drag the File Upload field onto the form layout and configure it:

Banners and Alerts

1) Determines is uploading the file is required.

2) Private: Don't set to private unless you want only user and CMS Admin to be able to access the file. It will not be visible in Salesforce if synched.    This cannot be reversed if files were previously uploaded as private, so not set to Private without fully considering your need to access these files.

3) Is File an Image?  This is optional, but allows you specify a recommended width and recommended height for the image.  This value is not enforced however.  

4) Save to Salesforce:  Select this if you wish the file saved to Salesforce

5) Salesforce Library - Salesforce can optionally save files in a library.  You do not have to choose a library or create one, in which case it will be put in the default Salesforce Library. If you wish to create specific libraries for certain types of file uploads you can do so.  See this article from Salesforce Help on how to create and manage libraries.

6) Store as Related Files:  Setting this to 'yes' will associate the file with the record you are creating or updating in Salesforce.  In our example here, we are synching to the contact record (of the logged in user), so the file will be available as a related file to the logged in contact.

7) Extensions Allowed:  specify all the file types you are allowing to be uploaded.  You must select at least one to save the field and the form.  (Otherwise they can't upload anything!).  This allows you to limit uploads to documents, images, or whatever is appropriate.  (if Is file an Image is selected, you can only choose extensions for images).

8) Don't populate from Salesforce:  When checked the files associated with this contact will not be visible for the user to delete or edit.

NOTE:  If you do not choose to map the file to a library or as a related file to a record, you'll be presented with the option to map a URL to the file to a chosen URL field in Salesforce on the record you are updating.   In this case, the file will be stored externally from Salesforce, and you can access it through the URL populated in this field.


How Uploading Files works on a form on the public site.

Create a page for your form, and put in any helpful instructions.  Users can drag & drop or browse files to upload, and can upload multiple files at once.   After all files are uploaded, they would click Submit to finish the form and the files will be submitted.

Image (2).png

Subsequently - a logged in user will have access to the files they've uploaded (if you've selected "Populate Fields from Salesforce".

Image (2).png


Add your comment

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.