doing the main template