Database rewrite

Completly rewrote Database and Model; Database is now Singleton and uses
PDO instead of MySQLi; Model rewritten to accomodate changes and have
default functionality; User needs rewriting to accomodate changes.