hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xinjun Chen" <xjchen...@gmail.com>
Subject Re: HttpClient with attachment
Date Thu, 24 Aug 2006 06:03:16 GMT
Hi Roland,

The MultipartRequestEntity works perfectly in my test program. :-).
Thank you very much for your help during my test of HttpClient.

Regards,
Xinjun

On 8/23/06, Xinjun Chen <xjchen001@gmail.com> wrote:
> Hi Roland,
>
> Thank you for your responsive and helpful reply.
>
> I am sorry that I didn't make my question clear. What I am looking for
> is sending SOAP with attachment. Before last email, I looked into the
> source code of Method.setRequestEntity() and found that existing
> request entity is always cleared before setting the new request
> entity.
>
> I think the MultipartRequestEntity is the one I am looking for. :-).
> Correct me if I am wrong. I will try it and let you know the result.
>
>
> Regards,
> Xinjun
>
> On 8/23/06, Roland Weber <http-async@dubioso.net> wrote:
> > Hello Xinjun,
> >
> > > Could anyone provide me some link or idea on how to use HttpClient
> > > with attachment?
> >
> > I have no idea what you mean. Attachments are something you put
> > in EMails. HttpClient is not an EMail client!?
> >
> > In case you want to send files with your HTTP requests, have a look
> > at FileRequestEntity (file only) and MultiPartRequestEntity (HTML
> > form parameters with files). The latter can handle a FilePartSource.
> >
> > http://jakarta.apache.org/commons/httpclient/apidocs/org/apache/commons/httpclient/methods/FileRequestEntity.html
> > http://jakarta.apache.org/commons/httpclient/apidocs/org/apache/commons/httpclient/methods/multipart/MultipartRequestEntity.html
> > http://jakarta.apache.org/commons/httpclient/apidocs/org/apache/commons/httpclient/methods/multipart/FilePartSource.html
> >
> > hope that helps,
> >  Roland
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: httpclient-user-help@jakarta.apache.org
> >
> >
>

---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpclient-user-help@jakarta.apache.org


Mime
View raw message