login via popup window; misc fixes