Added for loop to display error code on login page.