[prev in list] [next in list] [prev in thread] [next in thread]
List: zope
Subject: [Zope] Re: ASP404 on Win2003
From: Brian Sullivan <briansullivan () gmail ! com>
Date: 2005-11-29 2:18:51
Message-ID: c3c01f30511281818y765de93bsdfe81180010b11ee () mail ! gmail ! com
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
On 11/24/05, Brian Sullivan <briansullivan@gmail.com> wrote:
>
> I have for a while successfully used the ASP404 script (
> http://www.zope.org/Members/hiperlogica/ASP404) front ending part of a
> zope server using IIS on Win2000.
>
> Recently I changed the front end server to Win2003. I have been attempting
> to use the same technique there. All seems to work except for the fact that
> the "FORM" part of the request header appears to go missing during the
> process -- so all form submits in my particular case fail. I have yet to
> determine the root cause, but near as I can tell the "FORM" request segment
> loss happens before the asp script gets to handle the redirection,
> presumably a change in Win2003's 404/405 error handling strips this out
> intentionally or inadvertently?
>
> Are others seeing this same phenomenon? Any work around?
>
I figured out what the problem was -- it seems the ASP404 script depends on
REQUEST_METHOD set in the request header to decide what mode to open WinHTTP
in. On Win2000 the REQUEST_METHOD is set to the method of the request
(GET/POST). On 2003 the method is always set to GET regardless of the
original method.
The only solution I could find was to use Request.totalbytes > 0 as a check
to set the WinHTTP open mode. Something like:
openmode = Request.ServerVariables("REQUEST_METHOD")
if Request.totalBytes > 0 then
openmode ="POST"
end if
zopeServer.Open openmode, zopeRequest, False
Somehow it seems like not a very satisfying solution but it serves my
purpose at this point.
[Attachment #5 (text/html)]
<br><br>
<div><span class="gmail_quote">On 11/24/05, <b class="gmail_sendername">Brian \
Sullivan</b> <<a href="mailto:briansullivan@gmail.com">briansullivan@gmail.com</a>> \
wrote:</span> <blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px \
0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid"> <div>I have for a while successfully \
used the <span class="st0" id="st" name="st">ASP404</span> script (<a onclick="return \
top.js.OpenExtLink(window,event,this)" \
href="http://www.zope.org/Members/hiperlogica/ASP404" target="_blank"> \
http://www.zope.org/Members/hiperlogica/<span class="st0" id="st" \
name="st">ASP404</span></a>) front ending part of a zope server using IIS on Win2000. \
</div> <div> </div>
<div>Recently I changed the front end server to Win2003. I have been attempting to \
use the same technique there. All seems to work except for the fact that the \
"FORM" part of the request header appears to go missing during the \
process -- so all form submits in my particular case fail. I have yet to \
determine the root cause, but near as I can tell the "FORM" request segment \
loss happens before the asp script gets to handle the redirection, presumably a \
change in Win2003's 404/405 error handling strips this out intentionally or \
inadvertently? </div>
<div> </div>
<div>Are others seeing this same phenomenon? Any work \
around?</div></blockquote></div> <div><br> </div>
<div>I figured out what the problem was -- it seems the ASP404 script depends on \
REQUEST_METHOD set in the request header to decide what mode to open WinHTTP in. On \
Win2000 the REQUEST_METHOD is set to the method of the request (GET/POST). On 2003 \
the method is always set to GET regardless of the original method. </div>
<div> </div>
<div>The only solution I could find was to use Request.totalbytes > 0 as a check \
to set the WinHTTP open mode. Something like:</div> <div> </div>
<div><font face="courier new,monospace">openmode = \
Request.ServerVariables("REQUEST_METHOD")<br>if Request.totalBytes > 0 \
then<br> openmode ="POST"<br>end if<br>zopeServer.Open openmode, \
zopeRequest, False </font></div>
<div><font face="Courier New"></font> </div>
<div><font face="">Somehow it seems like not a very satisfying solution but it serves \
my purpose at this point.</font></div>
_______________________________________________
Zope maillist - Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
** No cross posts or HTML encoding! **
(Related lists -
http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope-dev )
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic