Home > Form Elements > Bucket
General Usage
How to Use a Bucket
The basic idea behind a bucket is to take a sortable page layout and add a group or free-form elements to it. The elements move as one group with the bucket, but can be positioned individually within the bucket.
Using buckets is simple:
Simply click the bucket icon to add one to a page. We can then drag the lower right hand corner of the dashed outline to resize the bucket as needed. It's important to note the dashed outline does not appear in the final form.
To add elements to a bucket we simply click the bucket to select it, then click on the form field element we wish to add. The new form field element will be added to the bucket instead of as a new sortable element in the larger form layout.
We can then position the item in the bucket as needed in what amounts to a free form layout.
The benefit here is that we can still move the bucket around the sortable layout, resize the bucket, and so on, but we also have the ability to show and hide the bucket and its children like any other form element.
This means we now have a group of elements which can be moved as a group, but still positioned individually.
Moving Elements From One Page/Bucket To Another
We can move any valid element from one page or bucket to another.
That is, if we have an element on a page that element can be dragged on top of the bucket item, even if it's from a different page.
The bucket will turn green and when we release the mouse button that item will now 'belong' to that page and bucket.
We can check the bucket ownership of any item by mousing over it. The parent bucket (if any) of that field tiem will display a blue dashed outline.
Please note that in order to prevent accidental item removal FormBoss will 'stick' the form element to the edge of the bucket for about 50 pixels. Once we drag the element past that inital 50 pixels however, the item will release from the parent bucket and can be dropped as needed.
Bucket Limitations And General Hints
What is a Repeating Bucket?
A repeating bucket is one that allows our forms users to click a button to add or remove instances of the bucket and all its items at runtime. This is a very handy feature for times when we may not know exactly how many of some group of fields we need.
For example, a forms allows a user to fill in an address, but we want to allow for several distinct addresses if needed. This could of course be handled by creating a bucket, duplicating it, then using conditional show/hide logic with a checkbox. However, with repeating buckets we simply say make this item able to be duplicated, and then leave it up to the user to decide how many addresses they wish to add (though we can of course set a maximum number of buckets the user can create).
As useful as this is, their is one potential drawback you should be aware of before using repeating buckets: they usually increase the complexity of your data store if using a custom database via SQL+.
This increase in complexity isn't too harsh, but is usually means the extra instances of data we want to store will need to be sent to a second database table which is then related, via a key, to the 'main' entry table the rest of the form fields belong to. This means we'll now have two SQL+ items in our form, as well as when pulling data back out, the ability to write SQL JOIN statements to relate the two tables.
In short then we could consider using bucket repeaters an "advanced" feature, as the data requirements usually mean greater sophistication in terms of saving and retrieving data. Thus, it always pays to consider the alternative, which is as noted above, just using conditional logic to show and hide the extra instances of the bucket items we need.
That said if we do not need SQL+ and instead wish to use Simple SQL or Simple Email, using bucket repeating logic can be a much faster route to include dynamic fields than conditional logic.
Please Note These Important Bucket Repeater Limitations:
Repeating Bucket Logic Enabled?
This feature allows us to say this bucket and its contents can be duplicated by the user at runtime.
Entry Limit
Entry Limit sets how many times a bucket can be duplicated.
Entry Limit Message
If the entry limit is exceeded, this is the message shown to the user alerting the user.
Add Animation
The animation effect to play when adding the bucket item.
Remove Animation
The animaiton effect to play when removing the bucket item.