Merging config files, fixing database connections.

I merged the config/app.json and config/db.json into config.json. I also fixed an issue where the app will create a new database connection each time page views or href clicks are set.