How to send HTTP POST Request with xml header In Java?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • shiko
    New Member
    • Jul 2012
    • 3

    How to send HTTP POST Request with xml header In Java?

    I made use of this link to send an HTTP POST Request,

    http://www.xyzws.com/Javafaq/how-to-use-httpurlconnecti on-post-data-to-web-server/139

    now i need to add an xml header to my request, how can i do that?
    header will look like:
    <header ver="3.3.0">
    <client>
    <id>le</id>
    <pwd>123456</pwd>
    </client>
    </header>
Working...