making the index and the template for the surveys