Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Ajax Jqery xml response - not able to read response

 
Sujatha Kalluri
Ranch Hand
Posts: 33
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

My servlet is returning the xml response( I set the content type as text/xml) but my javascript is not able to read the response, I am using Jquery and Ajax.

My servlet code is like this


My Javascript code is



I am not able to fetch the xml elements in the javascript, for example I tried to read "Grad" element in the above example. where am I going wrong.

thanks,
Sujatha.
 
Gregg Bolinger
GenRocket Founder
Ranch Hand
Posts: 15302
6
Chrome IntelliJ IDE Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try changing "XML" to "xml".
 
Sujatha Kalluri
Ranch Hand
Posts: 33
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Gregg Bolinger wrote:Try changing "XML" to "xml".


I changed it to 'XML' then suprisingly worked in firefox browser but not in IE 7.how to fix in IE then.
anybody can help me?

 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic