cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-users Mailing List Archives

RE: Download files from HTTP

From: <Chi.Hsiang.Chih_at_fortisinvestments.com>
Date: Mon, 3 Nov 2008 14:01:05 +0100

Thank you Ralph!!
It works now. (After overcoming the problem with ampersand in the URL).
 
Regards, Chi
 

________________________________

From: curl-users-bounces_at_cool.haxx.se
[mailto:curl-users-bounces_at_cool.haxx.se] On Behalf Of Ralph Mitchell
Sent: zaterdag 1 november 2008 3:39
To: the curl tool
Subject: Re: Download files from HTTP

On Thu, Oct 30, 2008 at 11:59 AM,
<Chi.Hsiang.Chih_at_fortisinvestments.com> wrote:

        Ralph,
         
        Thank you for the tip. I'm new to CURL, but find it great tool.
         
        Now I'm able to logon with cookies and redirection.
        curl -L -c newcookies.txt -d
"email=scott.tiger%40company.com&password=PASSWD" -x webproxy:8080
http://edw.morningstar.com/login.aspx/login.aspx
         
        But still can't download the file. What am I doing wrong?
        curl -L -O -c newcookies.txt -x webproxy:8080
http://edw.morningstar.com/download.aspx?action=ExtendedMasterlist
<http://edw.morningstar.com/download.aspx?action=ExtendedMasterlist>

I think you missed a bit - the "-c cookiejar" only *writes* cookies to a
file. On subsequent calls you need to tell curl to *read* the
cookiejar. I do every curl call like this:

   curl -s -S -L -b cookies -c cookies -x .........

Ralph Mitchell

-------------------------------------------------------------------
List admin: http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2008-11-03

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET