Integrating login page and database stuff