Kevin Dangoor wrote:
>
> it looks like there's no means to do so using built in mechanisms at
> present. Which is not to say it's difficult, just more manual. This is
> something that needs to be fixed soon.
>
> from turbogears import view
>
> class Foo:
> @turbogears.expose()
> def index(self):
> tclass = view.lookupTemplate("yourpackage.templates.templatename")
> t = tclass(yourdictionary)
> t.std = view.stdvars()
> return t.serialize(output="xml")
>
Thanks for that - it worked like a charm (after one small change):
t = tclass(**yourdictionary)
Robert