Completed new login code. Updated from shelves to SQL database and debugged. Code is now fully functional.