updated index to template