[mod_python] how to take the psp.PSP.run in a variable ?

Stefan Horomnea stefan at softexperience.ro
Wed Oct 10 13:15:08 EDT 2007


I have this code:

    tmpl = psp.PSP(req, filename='tp/myresult.tpl.html')
    tmpl.run(vars = kwargs)

My question is, how can I store the template contents in a variable. So 
the run method instead of printing making it return ?

Cause I really need this for taking the returning string, and using it 
as a piece in a greater template. Or doing some other stuff on that string.


More information about the Mod_python mailing list