add new functions to functions.php and add validation on register form in register.php