modified place to load template