templates chage and main file