login/logout function added