Re: [PHP] http 411 error with cURL

2004-10-09 Thread Nick Wilson
* and then Nick Wilson declared > > * and then Marek Kilimajer declared > > CURLOPT_HTTPHEADER - An array of HTTP header fields to set. ahhh [EMAIL PROTECTED] it! that dont work and niether does this: curl_setopt($ch, CURLOPT_HTTPHEADERS, array("Content-Length: $postL")); im off to be

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Nick Wilson
* and then Marek Kilimajer declared > CURLOPT_HTTPHEADER - An array of HTTP header fields to set. Marek, im sure you dont need to know this, but i think it's funny so maybe you will, i just went to bed, im now sitting here er.. without much on at the PC cos i just realized the same thing! - s

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Marek Kilimajer
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 -

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Marek Kilimajer
Nick Wilson wrote: * 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=$v

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Nick Wilson
* 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

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Nick Wilson
* 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"); or strlen($var . $var2=; ? cheers marek

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Marek Kilimajer
Nick Wilson wrote: * and then Nick Wilson declared * and then Marek Kilimajer declared * How to resolve this? header('Content-Length: ' . strlen($data_you_are_posting)); Ok, im with you Marek but how/where do i put it in my curl function? Not with CURL_POSTFIELDS for sure.. i've been lookin

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Nick Wilson
* and then Nick Wilson declared > > * and then Marek Kilimajer declared > > >* How to resolve this? > > > > header('Content-Length: ' . strlen($data_you_are_posting)); > > Ok, im with you Marek but how/where do i put it in my curl function? > Not with CURL_POSTFIELDS for sure.. i've bee

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Nick Wilson
* and then Marek Kilimajer declared > >* How to resolve this? > > header('Content-Length: ' . strlen($data_you_are_posting)); Ok, im with you Marek but how/where do i put it in my curl function? Not with CURL_POSTFIELDS for sure.. i've been looking through the options in the manual and dont

Re: [PHP] http 411 error with cURL

2004-10-09 Thread Marek Kilimajer
Nick Wilson wrote: hi all, Im getting an http 411 error when trying to post data with php's cURL functions. The spec says ***The message for this error code is "Length Required." The server refuses to accept the request without a defined Content- Length.*** Im confused on 2 points: * Is it the

[PHP] http 411 error with cURL

2004-10-09 Thread Nick Wilson
hi all, Im getting an http 411 error when trying to post data with php's cURL functions. The spec says ***The message for this error code is "Length Required." The server refuses to accept the request without a defined Content- Length.*** Im confused on 2 points: * Is it the server i am posti