java - HTTP POST using CURL in Linux -


help needed on finding corresponding curl command syntax corresponding below java code works.

working java code>

    httppost httppost = new httppost("/semp");     httppost.addheader("authorization", "basic u1zdllnptfjprte6anvxmmffdvc=");      stringentity stringentity = new stringentity("<rpc>command</rcp>", "utf-8"); stringentity.setcontenttype("text/xml");     httppost.setentity((httpentity)stringentity);      closeablehttpresponse response = httpclient.execute(targethost, (httprequest)httppost, localcontext); 

corresponding curl syntax needed? please on corresponding syntax curl

thanks in advance.

check curl man page. -u section.


Comments

Popular posts from this blog

javascript - Karma not able to start PhantomJS on Windows - Error: spawn UNKNOWN -

Nuget pack csproj using nuspec -

c# - Display ASPX Popup control in RowDeleteing Event (ASPX Gridview) -