On 11/5/06, Alberto Valverde <[EMAIL PROTECTED]> wrote:
> In trunk widgets can use different template engines (though it hasn't
> been tested much).
Very cool--thanks for the reply. I've added the template_engine
attribute, but I'm still not seeing what I expect. The Kid-based
template still prints nothing; a Genshi-based template gives a
traceback.
These are the widget definitions I'm using; each widget is being
called as ${w('World')}:
The widgets are defined as:
class HelloKidWidget(widgets.Widget):
template='''<p xmlns="http://www.w3.org/1999/xhtml"
xmlns:py="http://purl.org/kid/ns#">Kid says: Hello, ${value}!</p>'''
template_engine='kid'
hello_kid = HelloKidWidget()
class HelloGenshiWidget(widgets.Widget):
template='''<p xmlns="http://www.w3.org/1999/xhtml"
xmlns:py="http://genshi/edgewall.org/">Genshi says: Hello, ${value}!</p>'''
template_engine='genshi'
hello_genshi = HelloGenshiWidget()
I'll have more time to diagnose this tonight, so stay tuned. I'm still
not convinced it's something outside my own code. :-)
--
Tim Lesher <[EMAIL PROTECTED]>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears Trunk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/turbogears-trunk?hl=en
-~----------~----~----~----~------~----~------~--~---