completed shift to .tmpl files for templates