added login example, moved logins to external file, bug fixes