Created
September 17, 2020 13:40
-
-
Save nielslange/3b91ca5e9906a0cb77549c6fffe58427 to your computer and use it in GitHub Desktop.
Reorder EU VAT field on checkout page
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 | |
/** | |
* Reorder EU VAT field on checkout page | |
* | |
* @param $fields array The original array with the checkout fields | |
* @return $fields array The updated array with the checkout fields | |
* @see https://woocommerce.com/products/eu-vat-number/ | |
*/ | |
function smntcs_reorder_eu_vat_field( $fields ) { | |
$fields['billing']['billing_vat_number']['priority'] = 35; | |
return $fields; | |
} | |
add_filter( 'woocommerce_checkout_fields', 'smntcs_reorder_eu_vat_field', 11 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment