splitting the template file