• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to display XML data by servlet on browser ?

 
Nr Java
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I want to read xml data and store in string and display on browser? I am able to display XML form please help me .
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OK. What have you done so far? Where are you stuck?
 
Ankit Garg
Sheriff
Posts: 9521
22
Android Google Web Toolkit Hibernate IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Nemee, welcome to javaranch.

I want to read xml data


Do you want to read it from a file on the server or what??
 
Nr Java
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am reading XML from another server side and i have to create an object for .
 
Deepak Bala
Bartender
Posts: 6663
5
Firefox Browser Linux MyEclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nemee Ram wrote:I am reading XML from another server side and i have to create an object for .


If you manage to write more than a one line problem description we might be able to help your better

[EDIT]

enabled BB code for the quote
 
Nr Java
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Deepak Bala wrote:
Nemee Ram wrote:I am reading XML from another server side and i have to create an object for .


If you manage to write more than a one line problem description we might be able to help your better

I am able to read XML from other server ... and displaying XML on browser ( ((XML = reader.readLine()) != null) ) and parsing it while (tokenizer.hasMoreElements()) {
String token = tokenizer.nextToken();


String status = token;

writer.println("<br>");

writer.println(status);

I have to store XML data on pojo and create an object to use for another purpose..
PLease help me how to do ??

 
Deepak Bala
Bartender
Posts: 6663
5
Firefox Browser Linux MyEclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Browsers are capable of handling XML data by applying their own CSS to it. Simply pass the XML to the browser and set the appropriate MIME type
 
Nr Java
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for reply i done it myself ....
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic