This week's giveaway is in the JDBC forum.
We're giving away four copies of Java Database Connections & Transactions (e-book only) and have Marco Behler on-line!
See this thread for details.
Win a copy of Java Database Connections & Transactions (e-book only) this week in the JDBC forum!
  • 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:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

Missing message for key "welcome.title" in bundle "(default bundle)" for locale en_US  RSS feed

 
Greenhorn
Posts: 8
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As said earlier that html does not support locale attribute and you suggested to use lang attribute.i did accordingly but still i arise with this exception Missing message for key "welcome.title" in bundle "(default bundle)" for locale en_US

and i have wriiten this code in messageresource property
# -- welcome --
welcome.title=Struts Blank Application
welcome.heading=Welcome!
welcome.message=To get started on your own application, copy the struts-blank.war to a new WAR file using the name for your application. Place it in your container's "webapp" folder (or equivalent), and let your container auto-deploy the application. Edit the skeleton configuration files as needed, restart your container, and you are on your way! (You can find the application.properties file with this message in the /WEB-INF/src/java/resources folder.)

error.keyword.required=Search Key Word is required


but still arising with the same exception please help me in how to proceed further
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please post your struts-config.xml file and the JSP you are trying to display when this error occurs. Also indicate where you have placed your message resources properties file and what the name of it is.
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In a misplaced post, you indicated that the following entry exists in your struts-config.xml file.


The first thing wrong here is that you can only have one default message resource. If you want to have additional message resources, they must each have a unique key specified using the key attribute. Only the one default message resource does not need a key attribute.

The second problem is that you've specified package names for your resource files, but (again from your misplaced post) I understand that you placed the resource file in the root of the classes directory. If you specify a package, you must build a directory structure matching the package, just as you do with Java classes. And by the way.. that package name should never be java.

My suggestion is to change the entry in your struts-config.xml file to:

That way it will match what you already have in your classes directory and your JSP should work.
 
Greenhorn
Posts: 23
Android Scala VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I got the same problem (only with locale de) for blimey demo from a training course. And instead of concentrating on my course I now have to fix this stupidity. Why is Struts not just using the default language instead of a annoying error message? So from the course I take home: ”Struts is difficult to use better stick with POS (Plain Old Servlets) and JSP”.

Enough of ranting. Has anybody got a quick fix for this problem? Remember: just a throw away demo - no need for proper fix with real multi language support.
 
Martin Krischik
Greenhorn
Posts: 23
Android Scala VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I solved it myself with the follwing commands:



If you found this thread on Google (like I did) then remember that file and folder names may be different for you.
 
Bring out your dead! Or a tiny ad:
how do I do my own kindle-like thing - without amazon
https://coderanch.com/t/711421/engineering/kindle-amazon
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!