at index, it wrote: render.index(render.header(), render.foot()) at entry, it will be wrote: render.entry(render.header(), render.foot())
... O, write a lots of code.... do it has an easy way to bulid it? when i have not look for this one, i post a new entry at: http://groups.google.com/group/webpy/browse_thread/thread/b7cdc00f7e970396/2613459e4df7f7b3#2613459e4df7f7b3 On 9月26日, 上午7时49分, Tzury <[EMAIL PROTECTED]> wrote: > > web.render('index.html') it gives error as render not found in > > module. I have downloaded webpy0.22 and working on python2.5 . Is > > that method obsolete or removed ? plz let me know at the earliest > > At first you should define your render object initialized with > templates directory > > e.g. > render = web.template.render('templates/') > > Once you did so, you can call render.<template_file> > e.g. > for 'index.html' you call render.index() > > Moreover, if you have menu.html, header.html, footer.html which you > want them to appear at all pages you may do the following: > > render.index(render.menu(), render.header()) > and your index may look like: > $def with (menu, header, form, ....) > <html> > < blah> </blah> > <body> > $:header > $:menu > <form> > $:form.render() > </form> > </body> --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
