Implemens the login form as part of the app (for cordova)