Fixed up db connection problems...

Removing old index and template files...