On Tue, Mar 2, 2010 at 4:51 PM, benhoyt <[email protected]> wrote: > I'm used to, and quite like, the "simple inclusion" way of doing > things. Can someone explain the advantages of the "template > inheritance" approach?
My impression was that Templetor was written to be able to offer user-editable templates for your application's end users. If you allow them to randomly access render, they could easily break the site's layout, etc. I don't know if this was the real design goal, but that's the impression I got. You can always offer your users a pseudo-render: class foo: pass myrender = foo() myrender.template1 = render.template1 myrender.template2 = render.template2 # then you can: render.template3(myrender) If you want full control, there are other templating systems like Mako. -- Branko Vukelić http://foxbunny.tumblr.com/ http://www.flickr.com/photos/16889...@n04/ http://www.twitter.com/foxbunny http://github.com/foxbunny -- You received this message because you are subscribed to the Google Groups "web.py" 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/webpy?hl=en.
