Created
February 15, 2021 11:56
-
-
Save femiyb/51d369c900e6b9e327b51205a7def869 to your computer and use it in GitHub Desktop.
Move Payment Option fields
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 the following code to your PMPro Customizations Plugin - https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
* Move Payment Option fields | |
*/ | |
function pmpro_move_level_options_fields() { | |
global $pmpro_pages; | |
if(is_page($pmpro_pages['checkout'])) { | |
?> | |
<script> | |
jQuery( '#pmpro_level_options' ).prependTo( '.pmpro_checkout-field-username' ); | |
</script> | |
<?php | |
} | |
} | |
add_action( 'wp_footer', 'pmpro_move_level_options_fields' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment