(Bug 4715) HTML template generated in TT rather than JS