completed function register,login,logout,active and edit profile