Last active
October 9, 2021 04:37
-
-
Save cartimize/d670b5d10cb53a58fd39973d38160af4 to your computer and use it in GitHub Desktop.
How to activate the custom JS validator for the following fields (billing_address_1, shipping_address_1)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter('cartimize_get_billing_checkout_fields', 'cartimize_custom_get_billing_checkout_fields', 10, 1); | |
function cartimize_custom_get_billing_checkout_fields( $value ){ | |
$value['billing_address_1']['parsley_custom_validator']= true; | |
return $value; | |
} | |
add_filter('cartimize_get_shipping_checkout_fields', 'cartimize_custom_get_shipping_checkout_fields', 10, 1); | |
function cartimize_custom_get_shipping_checkout_fields( $value ){ | |
$value['shipping_address_1']['parsley_custom_validator']= true; | |
return $value; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment