Registration validation is a joomla plugin which validates user credentials while registering at your site. The default joomla validation is not sufficient enough to handle various cases and also it does not validate all the data prior to form submission.
What data does this plugin validates?
This plugin mainly validates the basic fields of the registration form that are username, email and password.
In current joomla registration process the validation is very limited and even some of the validation takes place after registration form submission. For user this becomes very tedious to fill the form again and again.
1. Validation on Username
- User must fill this field since it is a required field.
- Provided username must follow the alphanumeric standard and does not contains any symbol.
- Provided username must not exist in the system. This is completely ajaxified.
2. Validation on Email
- User must fill email field.
- Provided email is a valid email address
- Provided email must not exist in the system. This is ajaxified.
- Check confirm email field for correctness.
3. Validation on Password
- User must fill password field.
- Checks the password strength of the provided password. This plugin does not apply any extra password strength to the registration system. Default password strength of Joomla registration is considered here.
- Check confirm password field for correctness.
How to use registration validation
This plugin is very easy to use as there are no extra configuration needed to run the basic validation.
- Download this plugin from URL
- Install the downloaded plugin to your Joomla site and enable this from plugin manager.
- Now check the registration process.
On every validation error user will see proper error messages.
Like on providing existing username below message will appear.
When incorrect password filled in confirm password field :
Registration Validation Pro
This enhanced version will allow you to place custom validations in the registration process. Like apart from checking required and valid email you would like to allow registration for selected domain only say gmail and yahoo then you can impose this restriction in the registration using using the regular expression feature.
How to inject custom validation
- Go to plugin manager and open registration validation pro in edit mode.
- In this screen you will find three parameters which you can use to apply your custom validations on username, email and password. Here you need to put the regular expression for your validation.
Suppose you would like to allow the registration only for gmail email address or yahoo then in the Email Regex field place this regular expression (gmail.com$|yahoo.com$) to apply this validation.
After this, when any user tries to register with email of any other domain (other than gmail or yahoo ) then proper error message will be displayed.
Similarly you can apply custom validation on username and password.
How to change error messages?
All the error messages that registration validation and registration validation pro plugin displays to user can be changed by overriding its language file.
All the language tokens of Registration Validation plugin are available in the file en-GB.plg_system_f90_registration_validation.sys.ini and of Registration Validation Pro plugin are in the file en-GB.plg_system_f90_registration_validation_pro.sys.ini located at administrator/language/ directory.
For language overriding you can refer Joomla Documentation.