Re: LWP and $content

Gisle Aas (aas@oslonett.no)
Thu, 03 Aug 1995 17:53:32 +0200


>  Is it possible with LWP, to specify the name of a file to send when the
> method is `POST' ?

Not currently, so let's put it on the ToDo list.  In the meantime you might 
just do

   new LWP::Request($method, $url, $head, scalar(`cat $filename`));

Feel free to implement it in the context of LWP, send patches to me and I will 
incorporate it in the next release.

--Gisle



>  My problem is to implement `<INPUT TYPE=FILE>'.
> 
>  Normally, I make :
> 
>  $request  = new LWP::Request($method, $url, $head, $content);
> 
>  Where `$content' is the content of the message, but in this particular
> case I don't want to store the complete file in a variable (because this is
> probably a huge file). I just want to indicate to LWP::Request that the
> content must be read from a particular file.
> 
>  Is this possible actually with LWP::Request, or with another module of LWP ?
> 
> 
> Guy Decoux
>