[Lazarus] Brook-fpWeb POST without fields

silvioprog silvioprog at gmail.com
Thu Mar 20 22:28:37 CET 2014


2014-03-20 16:28 GMT-03:00 Leonardo M. Ramé <l.rame at griensu.com>:
[...]

> Silvio, here's the solution. Just create a Post handler, then save
> TheRequest.Content string as a TFileStream:
>
> procedure TIndex.Post;
> var
>   lStream: TFileStream;
> begin
>   lStream := TFileStream.Create('output.odf', fmCreate);
>   try
>     lStream.Write(TheRequest.Content[1], TheRequest.ContentLength);
>   finally
>     lStream.Free;
>   end;
> end;


Oops, sorry for my confusion. Until then I had not understood the problem
hehe...

Michael is right, the Content property will get your buffer as stream! :)

-- 
Silvio Clécio
My public projects - github.com/silvioprog
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20140320/afd050a2/attachment-0003.html>


More information about the Lazarus mailing list