Thread View: borland.public.cppbuilder.internet.web
1 messages
1 total messages
Started by Mark Jacobs
Thu, 16 Sep 2004 10:17
Massive Content Lengths with TWebRequest
Author: Mark Jacobs
Date: Thu, 16 Sep 2004 10:17
Date: Thu, 16 Sep 2004 10:17
23 lines
1887 bytes
1887 bytes
I am puzzled. The help for TWebRequest states that the Content property may
not contain all of the content, because if it is greater than a certain limit
(48K ?), then the method ReadString can be used to get subsequent chunks from
the HTTP stream, until it returns an empty string. Assuming this is true, and
some of my clients' posts will be at least 64K in length, what happens to the
ContentFields property? Does this get updated with each ReadString or does it
only contain data for whatever was initially in the Content property? Would I
need to code it like this :-
// Assuming TWebRequest *Request etc...
AnsiString mycont=Request->Content;
while (mycont.Length()<Request->ContentLength)
{
nxtbit=Request->ReadString(32000);
if (nxtbit.IsEmpty()) break;
mycont+=nxtbit;
}
// then fill up Request->ContentFields from mycont somehow ?!?
--
Mark Jacobs
DK Computing
http://www.dkcomputing.co.uk
markj atty critical dotty co dotty uk
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads