Hi I'm generating a sprox form with Turbogears 2.1 and trying to display it in a mako template. Here is my code:
To define the form:
class NewUserForm(AddRecordForm):
model = User
newuserform = NewUserForm(DBSession)
The controller definition that assigns the form and calls the template:
@expose('limelight.modules.users.templates.register')
def register(self, **kw):
tmpl_context.register_form = newuserform
return dict(value=kw)
And the relevant template code:
${tmpl_context.register_form(value=value)}
The problem is the HTML code is displayed as plain text on the page, not rendered HTML. Any help would be much appreciated.
Thanks