• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to write customized Tag handler in Struts 2

 
Ranch Hand
Posts: 147
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I have below requirment.

I have two message resource properties file. for Example. - ApplicationResources.properties and ApplicationResources-Extn.properties. I have some key values in both files but both are different. ApplicationResources-Extn.properties is used for customization of message. My requirment is that when ever i use for example <fmt:message key="mainMenu.title" />, First it has to look in to ApplicationResources-Extn.properties to get the values. If it not found there, then it will go and do lookup in ApplicationResources.properties file and return back the value.

Please suggest how i can do this.

Regards,
Sunil
 
Ranch Hand
Posts: 485
Eclipse IDE Firefox Browser Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why do you need two resource bundles, what will happen if you are having all the values in a single file.
 
xsunil kumar
Ranch Hand
Posts: 147
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have one resource file for product. Second resource file may contain same key or may not. Second one will be used for customization. If I want to customize for one customer, then i will change value in second file. If customization is not required, then it will pick from first resource file.

So in one way i am avoiding duplication of properties file and want to achieve customization also.

Do you have any idea. I need to consider localization also.

Regards,
Sunil
 
xsunil kumar
Ranch Hand
Posts: 147
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I got some idea how to write such type of code. I have downloaded source code for tag lib and customized my class to get the desired result.

Regards,
Sunil
 
Mohana Rao Sv
Ranch Hand
Posts: 485
Eclipse IDE Firefox Browser Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Post your idea
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic