percious schrieb:
> To answer my own question:
>      @expose()
>      def export(self, **kw):
>          response = pylons.response
>          response.headers['Content-type'] = "text/x-csv"
>          response.headers['Content-Disposition'] = "attachment;
> filename=YOUR_FILE.csv"
>          return "1,2,3,4"

Basically the same as in TG 1.x except "response = cherrypy.response" 
:-) But CherryPy also has the serveFile function, which is better suited 
for serving large files. Does Pylons have something like this?

Chris

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" 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/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to