Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Adjust the language of the LifterLMS Stripe Credit Card Form.
<?php // don't copy this line to your functions.php file!
/**
* Adjust the locale of the Stripe.js credit card form.
*
* @param array $settings Array of settings.
* @return array
*/
function my_llms_stripe_js_locale( $settings ) {
// Adjust the locale of Stripe.js, see https://stripe.com/docs/js/elements_object/create#stripe_elements-options-locale for supported locales.
$settings['elements']['locale'] = 'auto';
return $settings;
}
add_filter( 'llms_stripe_elements_settings', 'my_llms_stripe_js_locale' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment