curl-users
Re: Using curl to download CBOE csv file quotes...help!
Date: Mon, 31 Jan 2011 17:58:12 -0500
On Mon, Jan 31, 2011 at 2:13 PM, <dsisk_at_nc.rr.com> wrote:
> Oh yeah, I've found the -c and -b cookie options...just not any example of
> how to use them with this blasted CBOE site! ;-)
>
>
Sigh - top-posting...
I usually just put a standard set of curl options at the top of my scripts,
then reference it later:
CURLOPTS="-b cookies -c cookies -s -S -L -m 30"
...
curl $CURLOPTS -o file.html http://server.domain.com/stuff/things/
If the cookie file doesn't exist, it gets created, relevant cookies are sent
to the host, all cookies are saved when curl exits.
Ralph Mitchell
> ---- Daniel Stenberg <daniel_at_haxx.se> wrote:
> > On Sat, 29 Jan 2011, dsisk_at_nc.rr.com wrote:
> >
> > > So there are cookies involved. Doesn't curl support a way to pass
> cookies
> > > to a site? Any idea how to formulate the curl command with cookie data
> in
> > > this particular situation?
> >
> > Sure it does. Use -c to store them to a file and -b to read them from a
> file.
> >
> > Surely searching for "cookie" in the man page would've found these...
>
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-01-31