• Resolved Fatma

    (@omandaisy)


    space in username should not accepted by wordpress default, but UM Form just allowed this since last month, which make my users confuse about their login name

    Can you help me to disable this.
    notice:
    username field accept other special characters it accept as @,#.. etc
    I need to allow only those (a-z), (0-9) & (- , _)

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Contributor Champ Camba

    (@champsupertramp)

    Hi @omandaisy

    Please try adding this code snippet to your theme/child-theme’s functions.php file or use the Code Snippet plugin to run the code:

    add_filter("um_validation_safe_username_regex",function( $regex ){
       return '|[^a-z0-9_.\-@]|i';
    });

    The above code will reject the space in the username.

    Regards,

    Plugin Contributor Champ Camba

    (@champsupertramp)

    Hi @omandaisy

    Please feel free to re-open this thread by changing the Topic Status to ‘Not Resolved’ if any other questions come up and we’d be happy to help. 🙂

    Regards,

    Thread Starter Fatma

    (@omandaisy)

    Thank you this was very helpful , it’s solved

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Space in username’ is closed to new replies.