New try with template refs #6