Logo 
Search:

Java Forum

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds

tomcat 4.0.5 - Passing XML string as a parameter to a servlet

  Asked By: Ryan    Date: Jul 28    Category: Java    Views: 1493
  

I am having problem with passing xml as parameter to a servlet using
tomcat 4-0-5 ( it works fine on tomcat 3.2 !) ( I open a connection
to the servlet from a java class & send xml string as a post
request )

The servlet request.getParameter("xmlstring") returns a null.

By experimenting I found that if from xml string I remove version=
form the <?xml version=\à.0\" ?> tag, then request.getParameter
("xmlstring") shows the string that I passed correctly. But then my
xml is malformed.

I have tried passing the xml string to the servlet from browser (get)
and by opening a connection & passing in the parameter (POST).
It gives the same error in both cases

Also this works fine if I use tomcat 3.2 as the server but I want to
upgrade the server to tomcat 4-0-5 & thats where I get this error

Does anyone knows why is this problem coming on tomcat 4.0.5 ?

Also what is the best practice for sending the xml to a servlet ?

Share: 

 

No Answers Found. Be the First, To Post Answer.

 




Tagged: