Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_action('wp_enqueue_scripts', function () {
- $script = '';
- if (is_wcfm_membership_page()) {
- $current_step = wcfm_membership_registration_current_step();
- switch ($current_step) {
- case 'registration':
- ob_start();
- ?>
- <script>
- jQuery(document).ready(function($) {
- if( $('.wcfm_email_verified_input').length > 0 ) {
- $('#user_email').off('blur');
- }
- });
- </script>
- <?php
- $script = ob_get_clean();
- break;
- }
- }
- if (is_wcfm_registration_page()) {
- ob_start();
- ?>
- <script>
- jQuery(document).ready(function($) {
- if( $('.wcfm_email_verified_input').length > 0 ) {
- $('#user_email').off('blur');
- }
- });
- </script>
- <?php
- $script = ob_get_clean();
- }
- wp_add_inline_script('wcfm_membership_registration_js', $script, 'after');
- }, 11);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement