Pricing Fields can be used to give your forms eCommerce functionality. There are 3 pricing field types: Product, Quantity, and Total.
Pricing field global options
All pricing values are displayed in the currency of choice. To change your currency, go to Formidable's Global Settings, then set the currency in the Other section of the General Settings tab.
The currency option also includes a hook to allow custom code to change the currency per form.
Product field options
Product fields can be displayed as dropdown, radio, checkbox, single product, or a user-defined value.
The radio, checkbox, and dropdown options allow you to add a list of products with their prices. These can then be selected while filling out the form.
Single Product
When you select the Single Product option, the product name and price will show in the form in a read-only way. This is perfect for forms where only one product should be selected any time the form is submitted.
User Defined
When you select the User Defined product type, it allows users to enter a product name and a number to be used as the price. This is perfect for forms using an open-ended donation-based pricing model where users can set the price that they want to pay.
Check our other docs for more information on standard fields within Formidable.
Quantity field options
Quantity fields allow users to easily choose how many products they want. Set the number range to put a limit on the number of products a user can select.
Note that properly calculating a total based on the quantity requires a product to be selected. The Product Field option appears if there are two or more product fields in a form. One or more product fields to be selected here. When multiple product fields are selected, the same quantity will apply to each of them. This is ideal for product variations when multiple quantities are allowed.
The Step option is designed for partial quantities. For example, a product field could include options with different hourly rates, and the quantity would hold the number of hours. In this case, partial hours could be billed.
Total field options
Total fields automatically calculate all the products and quantities in the form. They can also be used in custom calculations.
Related developer hooks
- Replace product field options with the frm_setup_new_fields_vars hook.