This was just a typo (that caused me a few hours of grief)

I had written 
self.response().setHeader('Content-Type:','application/octet-stream')

The Content-Type has a ':' after it.  I took that out and made it lowercase and all is 
well.

Thanks for your help.  

-Aaron



----- Original Message ----- 
From: "Ian Bicking" <[EMAIL PROTECTED]>
To: "Aaron Held" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Sunday, November 18, 2001 10:13 PM
Subject: Re: [Webware-discuss] SetHeader help


> Last time I looked there was a bug with headers being treated as 
> case-sensitive -- I don't know if this was ever fixed (?)
> 
> If so, perhaps if you set 'Content-type' it will work...?  Otherwise it
> looks right.
> 
> On Sun, 2001-11-18 at 20:25, Aaron Held wrote:
> > I cannot seem to replace the Content-Type header, is there any trick to this?
> > 
> > I am writing 
> > 
> > self.response().setHeader('Content-Type:','application/octet-stream')
> > self.response().setHeader('Content-Disposition:','attachment;filename=Report.xls')
> > 
> > in writeHTML or writeRespond, but the headers still say 
> > 
> > Content-Type=text/HTML
> > 
> > Content-Disposition is written as well.
> > 
> > Where is Content Type set?
> > As far as I can tell on Line 21 of HTTPResponse it will only get added if 
>headers==None
> > 
> > Any pointers would be great.
> > 
> > Thanks,
> > -Aaron
> > 
> > 
> > 
> > _______________________________________________
> > Webware-discuss mailing list
> > [EMAIL PROTECTED]
> > https://lists.sourceforge.net/lists/listinfo/webware-discuss
> > 
> 
> 
> 
> _______________________________________________
> Webware-discuss mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/webware-discuss



_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-discuss

Reply via email to