update template for inserting code