[Zope] RESPONSE.write()

Dieter Maurer dieter@handshake.de
Wed, 29 Aug 2001 21:31:07 +0200 (CEST)


Paz writes:
 > ... streaming with "RESPONSE.write"....

 > 1) I haven't done more work outside of MSIE 6. Is this method of
 > streaming working on all broswers?
I use it successfully with Netscape 4.x and IE 5.x.

 > 2) It seems that if you write a page, you have to write 100% no less of
 > the page otherwise the Wrtie() masks any normal html. Is there a way to
 > do both?
Any response through a "Keep-Alive" channel needs to know
when the response is complete (such that the channel can be reused).
Thus, they use the "Content-Length" response header to indicate
how long the response body is.
You must send exactly that many bytes. Only then the message
sent is correctly associated with the response.

 > i.e Use RESPONSE-write() to immeditaley put up you interface, and then
 > have the content come from normal html.
???? This sentence seems a bit difficult for me to understand....

You know you must ensure that after the first "RESPONSE.write"
you must be sure only to send response data. You must
not generate any exceptions or stream other data into the response
channel (as explained above).


Dieter