template for tree from xml template