added preferences, custom host, and remember me functionality