template fixing