replacing the index file