Skip to main content
All CollectionsUse cases
How to allow form users to pay an amount in a range
How to allow form users to pay an amount in a range

Limit form payments to a range. Use custom validation and RegEx for amounts between $min & $max.

Updated over 8 months ago

If you want the user to enter an amount within a range, for example, amounts between $300 and $1,000, and then pay for it, you can use the custom validation field.

For example, the following RegEx validation rule helps you accept numbers with up to 2 decimal points.

/^(?:[0-9]{1,5}|[0-9]{0,5}\.[0-9]{1,2})$/

Learn more about how you can set customized validation on form fields (RegEx) to make more validations and collect more unified data on your forms.

You can test your RegEx patterns and learn more about validation rules on this website.

Did this answer your question?