Features of User Meta Pro: WordPress User Management Plugin / I’d like to restrict users from creating usernames with special characters. How can i do this?

Use regex in a custom field to avoid special characters and use the custom field as username.
regex e.g: ^([a-zA-Z0-9]*)$
This regex will only allow alphabetical and numerical characters but not any special symbols or space.

In the Fields Editor, create your custom field. Name it exactly “Username” and then the meta key modify to user_login. Then on the Forms Editor, remove the default Username field, with your Username (custom) field. Make sure your custom Username field is selected as Required and Unique.

 

Posted in: Using User Meta Pro

Subscribe to our newsletter