curl-library
Re: Object Moved/Location cut-off ?
Date: Sun, 23 Jun 2002 23:16:36 +0200 (MET DST)
On Fri, 21 Jun 2002, Morph wrote:
> The first time I send my info to the side, they send back a cookie (and
> since I performed the curl with the
> curl_easy_setopt(plug_args->curl_handle, CURLOPT_COOKIEFILE,
> "mycookies.fil"), I'm assuming that enables the cookie parser as explained
> in the docs).
Yes, it should do that.
> They also send back an "Object Moved" header with the "Location:" of where
> I need to send curl next.
... unless you tell curl to do it, then you won't have to do it yourself.
> However, the "Location:" seems to be cut off, I only get the following in
> the header:
>
> HTTP/1.1 302 Object Moved
> Server: Microsoft-IIS/4.0
> Date: Sat, 22 Jun 2002 01:56:42 GMT
> Connection: close
> Location: http://cgi3.ebay.com/aw-cgi/eBayISAPI.dll?
This seems veeeery strange. Have you tried using a network analyzer or
anything to see if this really is curl not reading the full header or if the
header arrives broken?
> HTTP/1.1 501 Not Implemented
Does this follow the Location: header? In that case it looks even more weird.
> So where do I go from here?
Well, if it is possible, I'd like to see an as small program source code as
possible that can repeat this problem.
> I tried to make my own HTTP/HTML handling code, but it got too complicated.
> I was hoping curl would help.
curl is indeed capable or at least assumed to be capable of this.
-- Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/ ------------------------------------------------------- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/Received on 2002-06-23