File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Struts and the fly likes xml display in struts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "xml display in struts" Watch "xml display in struts" New topic

xml display in struts

Lisa Carter

Joined: May 29, 2003
Posts: 25
s is possible to display an xml file in struts?

i need to do a search using a form, based on the parameters generate an xml file in a separate screen. is this possible if so how?
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
A JSP can output an xml file instead of an html file. For a Struts application, just have your action populate a javaBean with the information and forward to a JSP that produces XML.

Here is a link that shows some examples of a JSP producing an XML document.

Consultant, Sima Solutions
Lisa Carter

Joined: May 29, 2003
Posts: 25
Thanks. I will give it a try right now.
I agree. Here's the link:
subject: xml display in struts