XML-JSP content Type problem
2 posts in topic
Flat View  Flat View

Posted By:   Hardik_Mehta
Posted On:   Tuesday, June 19, 2007 02:07 AM

Hi All,
Please help me out.
I am using AJAX and hence the have to display the response obtained from server in javascript variable on the screen and keep on refreshing it.
The problem here is that I am getting the entire XML along with tags as string (or Text) from the server as response and now I have to display it on the screen. The content type of jsp page will be automatically set to HTML since it will be having other HTML tags like
Note: Xml is mapped with XSL and standalone is working fine.


Re: XML-JSP content Type problem

Posted By:   Roseanne_Zhang  
Posted On:   Wednesday, June 20, 2007 09:10 AM

I am not clear what you are attempt to do. Just put my 2 cents here from my limited AJAX experiences.

You can display your XML fetched AS-IS into an edit box.

Or you can parse the xml you got by using javascript. Then change your display according to the XML content.

Re: XML-JSP content Type problem

Posted By:   Robert_Lybarger  
Posted On:   Tuesday, June 19, 2007 09:25 AM

Wait... your JSP page response includes bits of javascript?! Are you sure you want this / need this? Typically speaking, AJAX is only used to fetch raw data, not data, logic, and presentational elements. If you're doing the latter, you might have trouble finding someone willing (let alone sufficiently knowledgeable) to help you.
About | Sitemap | Contact