Hi,

Probably just making a dumb mistake here, but I'm having some trouble
getting Kid to work.

First, I added these lines to make_app() in middleware.py:

    myghty = config.template_engines.pop()
    kidopts = {'kid.assume_encoding': 'utf-8', 'kid.encoding': 'utf-8'}
    config.add_template_engine('kid', 'wiki.kidtemplates', kidopts)
    config.template_engines.append(myghty)

This caused it to blow up because config.template_engines is empty. So
I changed it to this:

    #myghty = config.template_engines.pop()
    kidopts = {'kid.assume_encoding': 'utf-8', 'kid.encoding': 'utf-8'}
    config.add_template_engine('kid', 'wiki.kidtemplates', kidopts)
    #config.template_engines.append(myghty)

In this case, it serves the template without evaluating it. Actually, I
think it's trying to evaluate it as a Myghty template, but there's
nothing for it to do with a Kid template except spit it back out. If I
change my controller's render_response to pass 'kid' as the first
parameter, then I get an exception: "exceptions.Exception: No engine
with that name configured: kid".

I have a feeling there are a couple of obvious lines of code I need to
add that I couldn't infer from the documentation at
<http://pylonshq.com/docs/0.9/template_plugins.html>.

If it simplifies things as a starting point, I'm just trying to convert
the QuickWiki example to use Kid templates.

Thanks,

-- 
Daniel


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" 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/pylons-discuss
-~----------~----~----~----~------~----~------~--~---

Reply via email to