Handle the register form