implemented the database class with PDO.
added Database class as a standalone file.