added login and register capability