Username check from the database while registering

Code to check whether the Username exists or not in the database while
registering.
- Added a function in the register dbio
- Added code to check the database in the controller
- Added code to verify the password in the controller (in case
javascript is unabled in the users machine)