On 08/12/05, Sylvain Hellegouarch <[EMAIL PROTECTED]> wrote:
> Until CP 2.1, CP defauts its content type to text/html, you will be able to
> change that globally from the config file though a line like:
>
> server.defaultContentType = 'application/xml'

Excellent, ready to switch from HTML to XHTML and the flick of a
config option :) Combined with kids outputformat, you can write in
validated xhtml and serve it as whatever the hell your customer wants
:)

> There will be also a new decorator called headers to set HTTP headers per page
> handler (exposed callable) like this:
>
> @cherrypy.expose
> @cputil.headers([('Content-Type', 'application/atom+xml'), 
> ('Content-Language',
> 'fr')])
> def atom(self):
>     return atom doc

Good. But is there a reason behind the cputil packaging? Or is this
just an example of how it could go? I would prefer cherrypy.headers(),
for consistency. Everything to do with controlling cherrypy is behind
the cherrypy namespace.

--
wavy davy

"True religion confronts earth with heaven
and brings eternity to bear on time"
  - A. W. Tozer

Reply via email to