iterate over tags in the temkplate
use a defined function in the template