Pricing Fields let you add eCommerce functionality to your forms. You can set prices for each product, choose the quantity, and calculate totals easily within your form.
Pricing fields
To begin using these pricing fields, add them directly from your form builder. There are three pricing field types: Product, Quantity, and Total.
Change currency
All pricing values are displayed in the currency of choice. To change your currency, navigate to Formidable → Global Settings → General Settings and set the currency.
If you want to change the currency for each form, use the frm_currency hook.
Product
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 list products with their prices. These can then be selected while filling out the form.
Single product type
When you select the Single Product option, the product name and price will appear in the form in a read-only manner. This is perfect for forms where only one product should be selected each time the form is submitted.
User defined type
When you select the User Defined product type, users can enter a product name and a number for the price. This is perfect for forms using an open-ended donation-based pricing model, where users can set the price they want to pay.
Check our other docs for more information on standard fields within Formidable.
Quantity
Quantity fields allow users to easily choose how many products they want.
- Number range. Set a limit on the number of products a user can select.
- Step. This 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.
Select product field
Note that you must to select a product to calculate the total correctly based on quantity. If your form includes two or more product fields, the Product Field checkbox will be available in the Quantity field options. This checkbox allows you to select the specific product associated with the quantity field.
When you select multiple product fields, the same quantity will be applied to each product. This feature is particularly useful for product variations that offer multiple quantities.
Total
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.