added security to register page