How to use HTTP Post to post multipart/form-data
we using biztalk post xml data 3rd party sites. leverage htmlform project allows specify input parameter such <data> , put xml in there. below in our construct message. on http port adapter, use outbound map to xmlform htmlform. ends doing form post final url xml in "data" field.
incomingxml = dialysisjobsmsg;
formxml.loadxml("<ns0:htmlform xmlns:ns0='urn:schemas-tkh-co-nz:htmlform-xmldefault'><data/></ns0:htmlform>");
formmessage1 = formxml;
xpath(formmessage1, "/*[local-name()='htmlform' , namespace-uri()='urn:schemas-tkh-co-nz:htmlform-xmldefault']/*[local-name()='data' , namespace-uri()='']") = incomingxml.outerxml;
formmessage1(http.contenttype) = "application/x-www-form-urlencoded";
formmessage1(http.enablechunkedencoding)= false;
myport_http_port(microsoft.xlangs.basetypes.address) = http://www.mypostingurl.com;
now, however, specific client, data on 2 mb...and need multipart/form-data upload.
we tried changing content type such as:
formmessage1(http.contenttype) = "multipart/form-data";
continues fail.
any idea on how can thie multipart/form-data posting on http??
michael hennessy
hi michael,
i suggest write custom pipeline component (see reference thread). resources (links) writing custom send pipeline can find in thread.
hth
regards,
steef-jan wiggers
mvp & mcts biztalk server
http://soa-thoughts.blogspot.com/
if answers question please mark accordingly
biztalk
BizTalk Server > BizTalk Server General
Comments
Post a Comment