Description
This filter is executed when creating the Stripe Card or Square field and can be used to modify the “Card Details” label.
Usage
add_filter( 'gform_card_details', 'change_details', 10, 2 );
Parameters
Examples
This example changes the default Card Details label:
add_filter( 'gform_card_details', 'change_details', 10, 2 ); function change_details( $label, $form_id ) { return "Credit Card Specifics"; }
Placement
This code should be placed in the functions.php file of your active theme.
Since
This filter was added in Stripe 2.6 and Square 1.0.
Source Code
Stripe add-on: This filter is located in GF_Field_Stripe_CreditCard::get_form_editor_inline_script_on_page_render() in gravityformsstripe/includes/class-gf-field-stripe-creditcard.php
Square add-on: This filter is located in GF_Field_Square_CreditCard::get_form_editor_inline_script_on_page_render() in gravityformssquare/includes/class-gf-field-square-creditcard.php