I was following the example here:
http://groups.google.com/group/web2py/browse_thread/thread/f15668449a41362/afdca6efdf668fbb?lnk=gst&q=stream#afdca6efdf668fbb
to stream PDF files. Everytime I would try to open a pdf file,
though, IE6 would error "File Not Found". It worked fine in Firefox.
Turns out it's a bug in IE6 with how CherryPy sets it's default
response headers. Setting the additional headers of Pragma and Cache-
Control fixed it:
response.headers['Content-Type'] = "application/pdf"
response.headers['Content-Disposition']="attachment;
filename=BarCodes.pdf"
response.headers['Pragma']="cache"
response.headers['Cache-Control']="private"
return response.stream(pdfContents,chunk_size=4096)
Just wanted to get that out there so it would be searchable in the
future.
Thanks.