Responding to web request with python
Tim Roberts
timr at probo.com
Sun Nov 2 00:41:14 EDT 2008
scott212 <busitones at gmail.com> wrote:
>
>I'm responding with xml to a web request from google checkout but I
>think I'm in a catch-22. To get my webserver (apache) to respond I
>need a header and then a blank line before my xml begins, or else it
>throws the 500 error. If have the blank line before the xml, the
>service I'm responding to cannot parse it. If it's a response, can I
>still use urllib or something like that? Is that my answer?
You must be misunderstanding something. The HTTP protocol REQUIRES that
the headers and the content be separated by a blank line.
Perhaps you should try to use a debug proxy to intercept the exact text of
the response, just to make sure you're sending what you think you are
sending.
--
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.
More information about the Python-list
mailing list