implementing template engine
implementing template engine