开发者

How to send xml data in request in JSP?

I need 开发者_开发问答to send my request as a xml to servlet from jsp. how can i do that?


Two ways (in case by 'jsp' you mean 'from the browser'):

  • with form submit - with a <form method="post" action="..">. You will have to prepare the XML (with javascript for example) and set it in a field a request parameter, then parse the request parameter on the servlet
  • with ajax - using XMLHttpRequest or a framework like jQuery. With it you can submit anything.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜