On Wed, Oct 14, 2009 at 11:17 AM, ryan alford <ryanalford...@gmail.com> wrote:
> Here is the code...
> http://pastebin.com/m7ea04ea2
> Last night, that code worked(with the content length being commented out).
>  This morning, it gives me the "length required" error.
> Ryan

I am not extremely familiar with C#, but you might want to run a trace
to see what exactly the HTTP request headers are that you are sending.
Are you calling this code only for posting an update? Or are there
other methods using this code as well?  I know for requests like
friendship/create you have to set the content-length to 0 for the
request to work if you specify the username in the URL...

-Chad


>
> On Wed, Oct 14, 2009 at 11:09 AM, Chad Etzel <c...@twitter.com> wrote:
>>
>> Can you post your code snippet (in something like pastie or pastebin)?
>> Content-length should almost always be required for POSTs (from HTTP
>> spec).
>>
>> -Chad
>>
>> On Wed, Oct 14, 2009 at 8:56 AM, eclipsed4utoo <ryanalford...@gmail.com>
>> wrote:
>> >
>> > Ok, this is really starting to screw with me.  On Sunday, I received
>> > this error.  I put in code to send the content length when making a
>> > status update.  It worked on Sunday.  On Monday, the POST request
>> > started hanging.  For two days, I tried to figure out what the problem
>> > was.  So last night, I removed the code to add the content length.  IT
>> > WORKED!!!
>> >
>> > Now, this morning, I am getting the error again that the length is
>> > required.
>> >
>> > So which is it?  Is the length required or not?  Last night it was not
>> > required, this morning it is.  If I send it and it's not required, it
>> > hangs the request indefinitely.  If I don't send it and it's required,
>> > I get an error message.
>> >
>> > Any help?
>> >
>
>

Reply via email to