🎉 Celebrate with 10% OFF on All Products! Use Code: GFEX10 Or Buy Any 2+ Items for 30% OFF with Code: GFEX30!

Gravity Forms Media Library Folders Premium Add-on Setup Guide

Updated 8 min read Gravity Forms Integrations A–Z
On this page
  1. Video walkthrough
  2. What you need
  3. Install and activate
  4. Your first feed
  5. How a file gets into a folder
  6. Which files are used
  7. Choosing the folder
  8. A folder chosen here
  9. One folder per upload field
  10. A folder named by a template
  11. Folders that visitors can make
  12. A folder for each entry
  13. Title, alt text and caption
  14. Entry screen, entry list and merge tags
  15. Conditional logic, payments and notes
  16. Files and privacy
  17. What it does not do
  18. Troubleshooting
  19. Questions
  20. Can I use both folder plugins?
  21. Does it work with the paid versions of the folder plugins?
  22. Can visitors upload without an account?
  23. Is the original file changed?

Video walkthrough

Gravity Forms Media Library Folders: Put Uploaded Files in FileBird Folders (Free Plugin)
Video tutorial: Gravity Forms Media Library Folders Watch on YouTube

The Gravity Forms Media Library Folders Premium Add-on copies the files your visitors upload through a Gravity Forms File Upload field into the WordPress Media Library and puts each one in a folder of FileBird or Real Media Library. You choose the folder by form, by upload field, by a name built from the answers, or you let the add-on make one folder for every entry. The file also gets a proper title, alt text and caption from the form, so nobody has to rename IMG_4032 by hand.

Nothing leaves your server and no outside service is contacted. The add-on only uses the folder functions that the two free folder plugins already have.

What you need

  • WordPress 6.5 or newer and PHP 7.4 or newer.
  • Gravity Forms 2.9 or newer. The add-on is tested with Gravity Forms 3.1.2 on PHP 8.3 and Gravity Forms 2.9.8 on PHP 7.4.
  • One of the free folder plugins from WordPress.org: FileBird (tested with 6.5.9) or Real Media Library Lite (tested with 4.23.7). Both can be active at the same time.
  • An active license key for this add-on.

If no folder plugin is active, the add-on says so with a notice in the WordPress admin and on the feed list, and a feed does nothing until one is active.

Install and activate

  1. Install and activate the add-on like any plugin, after Gravity Forms and the folder plugin.
  2. Open Forms → Settings → Media Folders and enter your license key. Without an active license no feed can be created and no file is copied.
  3. Open the form that has a File Upload field, go to Settings → Media Folders and add a feed.
A Gravity Forms project intake form with the fields Your name, Your photo, Department and Your document, filled in with a photo and a PDF ready to send
An ordinary Gravity Forms form: the visitor sees nothing about folders.

Your first feed

A feed is one rule: when this form is sent, take the files and put them in this folder. Give the feed a name, leave the File Upload fields ticked, keep A folder chosen here and choose a folder from the list. The list shows the folders of FileBird and of Real Media Library that exist now, with their path and number. Save the feed, send the form once with a file and open the Media Library: the file is there, inside the folder.

The Media Folders feed settings: the File Upload fields, the folder choice with one folder per upload field, the folder per entry option and the file details with merge tag buttons
The feed settings: which folder, a folder per upload field, a folder per entry and the file details.

How a file gets into a folder

For every uploaded file the add-on checks that the name is allowed and that the file really sits inside the Gravity Forms upload folder, copies it into the Media Library with the normal WordPress routine (so WordPress checks the type and makes its thumbnail sizes for pictures), sets the title, the alt text and the caption, and then asks the folder plugin to put the new item in the folder. The copy that Gravity Forms keeps for the entry stays where it is.

FileBird keeps its folders in its own tables and the folder of a file is a row in a relation table. Real Media Library does the same with its own tables. The add-on never writes to those tables directly: it calls the functions of the plugin, so the folder counters and the folder tree stay correct.

Which files are used

Every File Upload field of the form is ticked by default; untick a field to leave it out. The single file field and the multiple file uploader both work. Any file type that WordPress allows in the Media Library is copied: pictures, PDF files, office documents, audio and video. Files with a script extension are never copied, and a name such as shell.php.jpg is refused as well. Most files per entry sets a limit from 1 to 50; extra files are skipped with a note on the entry.

Choosing the folder

A folder chosen here

The simplest rule. Pick one folder and every file of the form goes there. The form is the unit: one form, one folder.

One folder per upload field

When the form has several File Upload fields, the feed shows a box Folder for each field. Choose a different folder for each field, for example photos in one folder and documents in another. A field without its own folder uses the folder chosen above. The two folders may even belong to different folder plugins: a photo can go to a FileBird folder and a document to a Real Media Library folder in the same entry.

A folder named by a template

Switch Folder to A folder named by a template and type the name with merge tags, for example Clients/{Department:3}. The tags {entry_id}, {form_title}, {user_login} and {date} also work. A slash makes a sub folder, up to three levels. If the folder does not exist yet, the add-on makes it; the next entry with the same name finds it and reuses it. FileBird gets real sub folders. Real Media Library Lite has no sub folders, so the levels are joined: the example becomes one folder called Clients – Sales.

Choose the folder plugin for a template feed, or leave The one that is active, which uses FileBird first and Real Media Library when FileBird is not active. With Inside this folder you can start the template under a folder you already have (FileBird).

Folders that visitors can make

When the folder name comes from something a visitor types, anyone can make folders by typing new names. To avoid a messy library, switch off Make a folder that does not exist yet. The feed then uses a folder only when it already exists; otherwise the file stays in the Media Library without a folder and the entry note says so. Folder names are always cleaned: tags are removed, slashes make levels, dots and empty names are dropped and a name is cut at 80 characters.

A folder for each entry

Tick Also make one sub folder for each entry and every entry gets its own folder inside the folder chosen above, named by a template. The default is Entry {entry_id}; {Your name:1} – {entry_id} works too. This is useful for client intake, applications and anything where the files of one person must stay together. With FileBird the entry folder is a real sub folder. With Real Media Library Lite it is a separate folder called Folder – Entry 12.

Title, alt text and caption

The boxes Title, Alt text and Caption take merge tags, so you can use any field of the form. Extra tokens work in these boxes: {filename} (the file name without its extension), {index} (1, 2, 3 and so on for several files) and {entry_id}. An example title is {Your name:1} – {filename}. An empty title uses the file name and an empty alt text uses the title. The caption is plain text; HTML is removed.

Entry screen, entry list and merge tags

Every entry that was handled gets a box Media Library folder on the entry screen. It shows the folder path and the folder plugin for each group of files and every file as a thumbnail with a link to its Media Library page. The entry notes list what was made, what was skipped and why.

The Media Library folder box on a Gravity Forms entry screen: the folder path, the folder plugin and the thumbnails of the files that were copied
The entry screen shows the folder each file went to and the files themselves.
  • {media_folder_name}: the name of the folder (the last level).
  • {media_folder_path}: the full path, for example Clients / Sales.
  • {media_folder_id}: the number of the folder.
  • {media_file_count}: how many files were copied for the entry.

Use them in confirmations and notifications. With two feeds on one form the tags describe the last one. The entry list gets two optional columns and filters: the folder and the number of files.

Conditional logic, payments and notes

The feed has the usual condition box: copy the files only if a field has a value. If the form takes a payment, the option Copy the files to the Media Library folder only when payment is completed waits for the payment.

Files and privacy

The add-on contacts no outside service. It copies files that Gravity Forms already stored on your server into the Media Library, so each file exists twice: the copy of the entry and the copy in the library, plus the thumbnail sizes WordPress makes for pictures. Plan your disk space for that, and delete old entries and files in the usual way when you no longer need them. A file in the Media Library has an address that works for anyone who knows it, so do not send confidential documents there unless that is what you want.

What it does not do

  • It does not move files that were in the Media Library before the form was sent.
  • It does not use the paid features of the folder plugins. With FileBird the add-on uses the shared folder tree (the one every admin sees); the per-user folder mode of FileBird is not used. Real Media Library Lite has no sub folders.
  • It does not delete anything: folders and files stay when an entry is deleted.

Troubleshooting

  • No feed can be added: check the license under Forms, Settings, Media Folders, and that FileBird or Real Media Library is active.
  • Nothing happened after the form was sent: open the entry and read the notes. A skipped file, a folder that no longer exists or a feed condition that did not match is written there.
  • The file is in the library but not in a folder: the folder was deleted after the feed was saved, or the template folder did not exist and folders are not made automatically. The note says which.
  • The folder is not shown in the list: only folders of the shared tree are listed. Folders that belong to one user in the per-user mode of FileBird are not.

Questions

Can I use both folder plugins?

Yes. Both can be active. A feed puts files in the folder you choose, whichever plugin it belongs to, and a template feed uses the plugin you pick.

Does it work with the paid versions of the folder plugins?

The add-on uses the functions that the free plugins offer and that the paid editions are built on. It was tested with the free plugins only.

Can visitors upload without an account?

Yes. That is the normal case. The add-on needs no login.

Is the original file changed?

No. WordPress imports a copy into the Media Library. The file of the entry stays untouched.

Still need help?

Our support team answers tickets every day, usually within a few hours.

0
0
Your Cart
Your cart is emptyReturn to Shop
🔥 FREQUENTLY BOUGHT TOGETHER
Complete Combo & Save 40%!
ITEM IN YOUR CART
Gravity Forms Klaviyo Add-on
$39.00/yr
+
🎁 RECOMMENDED ADD-ON SAVE 40% OFF
Original Price: $39.00/yr
Bundle Special Price: $23.40/yr