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

curl-and-php

Re: Posting with an automatic hidden post

From: Andrey Kuznetsov <kandrey89_at_gmail.com>
Date: Wed, 4 Feb 2009 00:39:19 -0800

curl_exec=page refresh assuming it's the same url

Before you can extract data, you need to tell where you extract it
from, which is the variable that you set 1st curl_exec to. You extract
the key, then you select the same url, post command, and curl_exec the
POST command. Doesn't the 2nd curl_exec reload the page in order to
know where to POST command when it goes to the url thereby refreshing
and changing the key?

On Wed, Feb 4, 2009 at 12:13 AM, Daniel Stenberg <daniel_at_haxx.se> wrote:
> On Wed, 4 Feb 2009, Andrey Kuznetsov wrote:
>
>> Explain this:
>>
>> curl_init
>> URL
>> CURLOPT_RETURNTRANSFER
>> CURLOPT_FOLLOWLOCATION
>> curl_exec
>> extract key
>> URL
>> CURLOPT_POSTFIELDS
>> curl_exec
>> curl_close
>>
>> upon the 2nd url\curl_exec the page is reloaded,
>
> No it isn't. CURLOPT_POSTFIELDS implies a POST and it does not "reload" any
> page at all. Unless you by "reload" mean that it sends a request and gets
> contents back.
>
>> OR does curl-php work such that every line is executed as it is written,
>> and does not buffer url, return transfer, post-true, etc... until curl_exec
>> is issued?
>
> I'm not sure what you mean, but yes the request is done by curl_exec().
>
> --
>
> / daniel.haxx.se
> _______________________________________________
> http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
>
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2009-02-04