first click handler for login