• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Ganesh Patekar
  • Stephan van Hulst
  • Pete Letkeman
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Ron McLeod
  • Vijitha Kumara

Creating Tabs in JSP using xml file  RSS feed

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
i need to create tabs in JSP page. One way is to include the tabs in the JSP page itself. But i want to use an XML file as a source file for doing the same.

This will help in eliminating hard coding plus giving the advantage of easy modification.

Are there any APIs that allow me to use XML for creating tabs?

Thanks & Regards,
Mehul C Mandge
 
Sheriff
Posts: 21459
96
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are many ways of reading XML. The easiest way is using DOM; JDOM can help you, but also the standard API:
Alternatively, you can use SAX or StAX for parsing and handling the events. You can even use XMLStreamReader or XMLEventReader, but if you want the easy way, DOM is the way to go.
 
mehul mandge
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi rob.

i am thinking of some way where i can just specify the name of the XML file and it will create tabs accordingly.

hope i have made myself clear.

its clear that i can read the xml file and make tabs. e.g this is the code that i am including in my JSP




but i want that the tabs foo and bar should be defined in some xyz.xml and then i use some code similar to

<tab:tabContainer id="foo-bar-container" some_attribute="xyx.xml"/>

This will be much easier.
Thanks.
 
Rob Spoor
Sheriff
Posts: 21459
96
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Since the issue is now purely JSP related, let me move it to our JSP forum.
 
Author and ninkuma
Marshal
Posts: 66806
168
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is no such API.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!