Skip to content

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