Created
August 14, 2024 16:32
-
-
Save MaximilianoRicoTabo/b14ce1f2e32e2a59e4fa31392d68f82d to your computer and use it in GitHub Desktop.
hide state from billing address
This file contains hidden or 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 | |
/** | |
* Hide the billing state field on the checkout and billing pages. | |
*/ | |
function wp_head_hide_billing_state_field() { | |
global $pmpro_pages; | |
if ( empty( $pmpro_pages ) || ( ! is_page( $pmpro_pages['checkout'] ) && ! is_page( $pmpro_pages['billing'] ) ) ) { | |
return; | |
} | |
?> | |
<style> | |
#pmpro_billing_address_fields div.pmpro_form_field-bstate { | |
display: none; | |
} | |
</style> | |
<?php | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment