templates working
templates implemented