[Zope] error with simple python script loop

Maciej Wisniowski maciej.wisniowski at coig.katowice.pl
Sat Nov 25 03:53:39 EST 2006


> The third script has no output on the screen too but works fine and
> gives HTTP Code 200 back. Can you tell me why he do this?
This is because of call to ZPT in your third script. ZPT call sets
RESPONSE HTTP headers with content/type='text/html'. Try this:

for i in range(2):
  context.MailHost.send('bodytext', "rec at mail.com", "sender at mail.com",
 'subj'+str(i))
container.REQUEST.RESPONSE.setHeader('content-type', 'text/html')

And you should get 200 OK status too.

You may compare these results from IE with results from Firefox. There
is LiveHttpHeaders plugin for FF that will show you similiar output as
above (but in FF environment).

In general seems that it is a IE bug.

-- 
Maciej Wisniowski



More information about the Zope mailing list