petaganayr
asked on
Mandatory fields and username restrictions on a WordPress site.
Hello!
I have a WordPress site but I have no experience with PHP. The website has an account sign up page.
I'd like to make filling out the 'First Name' and the 'Last Name' fields a requirement when users sign up for an account. I'd also like to implement 'Username' creation restrictions, for example:
The following special characters are not allowed:
" / \ [ ] : ; | = , + * ? < >
For the required fields, I can probably copy the code from the other required fields that is already in place. But the restriction I don't know how to do. Does anybody have a sample code that I can take a look at?
Thank you in advance!
I have a WordPress site but I have no experience with PHP. The website has an account sign up page.
I'd like to make filling out the 'First Name' and the 'Last Name' fields a requirement when users sign up for an account. I'd also like to implement 'Username' creation restrictions, for example:
The following special characters are not allowed:
" / \ [ ] : ; | = , + * ? < >
For the required fields, I can probably copy the code from the other required fields that is already in place. But the restriction I don't know how to do. Does anybody have a sample code that I can take a look at?
Thank you in advance!
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you for the comments. I chose Mark's comment because I used his example and made my own lines of codes.
ASKER