cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

Re: Curl-and-php Digest, Vol 9, Issue 8

From: Tommaso Trani <trani_at_softwareplanet.net>
Date: Tue, 12 Oct 2004 20:47:22 +0200

> Message: 4
> Date: Tue, 12 Oct 2004 16:33:57 +0100
> From: Harry Fearnley <Harry.Fearnley_at_eng.ox.ac.uk>
> Subject: Re: Save CURL sessions
> To: Programming PHP/CURL <curl-and-php_at_cool.haxx.se>
> Message-ID: <416BF965.5000903_at_eng.ox.ac.uk>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Tommaso Trani wrote:
>
> > I would like to handle a curl connection between multiple executions
of my
> > php script.
> > For example I make a login to a private area (with curl) and then I wont
> > make some action in this area.
> > I would like to make just one time the login, than save the curl session
> > informations in a cookie, file or php session. So I can get this info
> > between multiple executions of my php script avoiding to make again the
> > login.
> >
> > Is it possible? I've tried to store the resource returned by curl_init
in a
> > sessions, but, of course, this way doesn't work because it's a resource
and
> > not a structured variable (I've tried using serialize, but it's a
resource
> > and doesn't work).
>
> If I have understood you correctly ...
>
> Can you make the action of the HTML form to call itself again,
> and simply pass the information as HIDDEN values in a form?
> Something like this:
>
>
> <FORM ENCTYPE="multipart/form-data" ACTION="this_file.html" METHOD="post">
> <INPUT TYPE="hidden" NAME="hidden1" VALUE="10485760">
>
>
> Harry
>

Yes Harry,
  it's as you said.

I want save the state informations of the curl sessions and then reuse this
state informations to resume the curl session starting from where I stopped.
Possible?

Thanks
Tommaso
Received on 2004-10-12