Form API

Form Template Function

The form template function accepts the following parameters as an array.

Parameters

Name Description Default
form The name of the configured form to use default
types The types this form supports [ 'one_off', 'subscription' ]
paymentMethods Parameters for payment methods see below
donationAmounts Names for the donation amounts to use see below
formOptions Options to pass to the Javascript API Form Options
stripeElementsOptions Options to pass to the Stripe Elements API Stripe Elements Options
stripeCheckoutOptions Options to pass to the Stripe Checkout API Stripe Checkout Options
paypalOptions Options to pass to the PayPal Checkout API PayPal Options
payfastOptions Options to pass to the Payfast Checkout API Payfast Checkout Options

paymentMethods

Name Description Default
stripeElements Options for Stripe Elements []
stripeCheckout Options for Stripe Checkout []
stripeCheckoutBacs Options for Stripe Checkout Bacs []
paypal Options for PayPal 'urlParams' => [ 'disable-funding' => 'credit,card' ]

donationAmounts

Name Description Default
one_off The one-off donation amounts to use one_off
subscription The subscription donation amounts to use subscription

On this page