moved stuff from main template to includes.