• Resolved kingdonkeykong

    (@kingdonkeykong)


    How to use it with Buddypress profile fields? There′s no option to add classes on forms. is there a way for you to develop this option? Or some workaround…

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Ivan Petermann

    (@ivanpetermann)

    Hi @kingdonkeykong,

    Try with the code below. Change PHONE-INPUT-NAME with input name to apply the mask.

    /**
     * Function to add custom mask. /wp-content/themes/YOUR-THEME/functions.php
     */
    function custom_masks_form_fields() {
        ?>
        <script type="text/javascript">
            jQuery(document).ready(function($){
                $("input[name='PHONE-INPUT-NAME']").addClass("phone_us");
            });
        </script>
        <?php
    }
    
    add_action('wp_footer', 'custom_masks_form_fields', 111);
    Thread Starter kingdonkeykong

    (@kingdonkeykong)

    it has not worked..but thank you anyway

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘No option to put class’ is closed to new replies.