1. Home
  2. Snippets
  3. Enable Credit Card field without Stripe addon

Enable Credit Card field without Stripe addon

Heads up!

This article contains PHP code and is intended for developers. We offer this code as a courtesy, but don't provide support for code customizations or 3rd party development.

For extra guidance, please see WPBeginner's tutorial on adding custom code.

Dismiss

The Credit Card field in WPForms will, by default, be hidden until the Stripe addon is installed and activated.

This is by design, as the Credit Card field will not store any details to your site’s database and is only able to send data to a third-party source (currently, Stripe is the only built-in option for this).

If you have built a custom integration, however, you may still need to use the Credit Card field.

To make the Credit Card field display in the form builder without the Stripe addon, you can add the following filter to your site:

/**
 * Include Credit Card field option in WPForms form builder
 */
add_filter( 'wpforms_field_credit_card_enable', '__return_true' );

Related

Updated on May 14, 2018

Was this article helpful?