Re: http 411 error with cURL

From: Date: Sat, 09 Oct 2004 23:50:47 +0000
Subject: Re: http 411 error with cURL
References: 1 2 3 4 5 6 7  Groups: php.general 
Request: Send a blank email to php-general+get-199088@lists.php.net to get a copy of this message
* and then Marek Kilimajer declared.... > Nick Wilson wrote: > >* and then Marek Kilimajer declared.... > > > >>>Opps! > >>> > >>>CURLOPT_HTTPHEADER > >>> > >>>I go play with it now ;-) > >>> > >> > >>Sorry, I got it mixed :) But you figured it out. > > > > > >do you know if the lenght includes the args? like this > > > >strlen("val=$var&val2=$var2"); > > This one. Don't forget to urlencode where necessary hmmm.. well, this is giving me the same curl_errno(22) http 411 $postF="s=$s&e=$e&a=" . urlencode($a) . "&em=" . urlencode($em) ."&x=" . $x . "&b=$b&t=" . urlencode($t) . "&p=$p"; $postL=strlen($postF); curl_setopt($ch, CURLOPT_POSTFIELDS,$postF); curl_setopt($ch, CURLOPT_HTTPHEADERS, "Content-Length: $postL"); $result=curl_exec($ch); -- Nick W

« previous php.general (#199088) next »