curl-and-php
Re: Curl + PHP = HELP!
Date: Mon, 11 Feb 2002 08:47:50 -0700
if the variables are being populated, then perhaps they contain wacky
characters that should be urlencoded??
Pete.
Dan Brown wrote:
> Hi everyone!
>
> I'm attempting to use CURLOPT_POSTFIELDS to post data. But the
> variable value is being ignored. Does anyone have any idea how to
> force it to pass the value? Or am I doing this wrong?
>
> curl_setopt($ch,CURLOPT_POSTFIELDS,"name1=$var1&name2=$var2");
>
> And it passes..
> name1=
> name2=
>
> The values for $var1 and $var2 are not passed. If I hard code the
> value, it passes. If it's a variable, it ignores it. I have verified
> that the variables are being populated, but curl doesn't send them?
>
> I'm using PHP and CURL on Apache running on Windows 2000. libcurl 7.9
> (OpenSSL 0.9.6a) and PHP 4.1.1
>
> PLEASE HELP THIS NEWBIE!!!
>
> Thanks!
> Dan
-- Pete James, AdvanisReceived on 2002-02-11