Added login button and fixed other weird login problems