thanks mike
but what about #include

for eg., webpy app
is

serverapp/
   app.py
   templates/index.html
   templates/test.html

so if i do
#include test.html
in index.html
it doesnt work as it is looks for test.html in serverapp directory instead
of serverapp/templates
On Sat, Mar 28, 2009 at 8:39 AM, Mike Orr <[email protected]> wrote:

> OK, I've never used web.py.  But the syntax indicates it does it in a
> framework-specific way, so you'll have to ask the web.py developers.
>
> You can of course use Cheetah the normal way if web.py allows it.
> That's how I did it in Quixote.
>
> from Cheetah.Template import Template
> t = Template(file=my_template_file, searchList=my_search_list)
> html = t.render()
>
> You'll have to double-check the Template argument names since I
> haven't used it for a while.
>
>
> On 3/28/09, [email protected] <[email protected]> wrote:
> > Hey mike it is webpy
> >
> > On Fri, Mar 27, 2009 at 12:56 PM, Mike Orr <[email protected]> wrote:
> >
> >> Are you the person who keeps asking how to use Cheetah in web
> >> applications without telling us which framework you're using?  It's
> >> totally different depending on the framework.  I have no idea what
> >> you're using except it looks like nothing I've ever seen before.
> >>
> >> On Fri, Mar 27, 2009 at 12:24 PM,  <[email protected]> wrote:
> >> >
> >> >
> >> >
> >> > In our controller , we do
> >> > import cheetah
> >> > return cheetah.render('test.html)#automatically sends **locals()
> >> > or
> >> > from template import render_cheetah
> >> > render = render_cheetah('templates')
> >> > return render.test(**locals())
> >> > I m unsure if this is the right way to use cheetah from a web-app
> >> >
> >> >
> >> > How do you guys use cheetah in your webapp? Is there a best practise?
> >> > Please share your cheetah modules as you have integrated with your
> >> webserver
> >> > thanks a lot
> >> >
> >> > --
> >> > Bidegg worlds best auction site
> >> > http://bidegg.com
> >> >
> >> >
> >> >
> >> > --
> >> > Bidegg worlds best auction site
> >> > http://bidegg.com
> >> >
> >> >
> >> >
> >> > --
> >>  > Bidegg worlds best auction site
> >> > http://bidegg.com
> >> >
> >>
> >>
> >>
> >> --
> >> Mike Orr <[email protected]>
> >>
> >
> >
> >
> > --
> > Bidegg worlds best auction site
> > http://bidegg.com
> >
>
>
> --
> Mike Orr <[email protected]>
>



-- 
Bidegg worlds best auction site
http://bidegg.com

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to