[albatross-users] ctx.request.write_header, AppContext, and Content-Types Oh my!

Michael C. Neel neel at mediapulse.com
Mon Feb 17 17:22:33 EST 2003


I've found that there are a few headers that the AppContext's set, and
these will overwrite those set by the page object.  I needed to set the
Content-Type in text/csv in my app, and to do this I had to comment out
the offending write_header line in the SimpleAppContext.

I did notice that leaving the line commented out, all the other html
pages were getting a Content-Type header of text/html, as they should.
If this is apache doing this, or Albatross I don't know, but sometimes
you don't questing working code too much.

I'd like to request that the AppContext's check for any existing header
before replacing that header in the next version, or if it is truly safe
to pull out the Content-Type header as I have done to just do that.  The
other header I saw being set was the no-cache header, which right now I
can't see a reason I'd wanna change that, but better safe than sorry and
allow the app to decide if it need to change the default.

Thanks,
Mike




More information about the Albatross-users mailing list