🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.web
Article #1559

Massive Content Lengths with TWebRequest

#1559
From: Mark Jacobs
Date: Thu, 16 Sep 2004 10:17
23 lines
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
Technical Details
Message-ID: <41496835$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: feeec,2260b51427f65972,start
X-Google-Attributes: gidfeeec,public
X-Google-Language: ENGLISH,ASCII-7-bit
Reply-To: "Mark Jacobs" <markj atty critical dotty co dotty uk>
From: "Mark Jacobs" <markj atty critical dotty co dotty uk>
Newsgroups: borland.public.cppbuilder.internet.web
Subject: Massive Content Lengths with TWebRequest
Date: Thu, 16 Sep 2004 11:17:32 +0100
Lines: 25
Organization: DK Computing
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
NNTP-Posting-Host: 81.144.157.8
Message-ID: <41496835$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1095329845 81.144.157.8 (16 Sep 2004 03:17:25 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail