abstracted database connection, added some logic to the php values

Added the _connect.php file which will be included in all database
facing pages. Added some logic to creating the form from the database.