Actually those 2 methods should provide the same output. This is from the
TagUtils.jsp, which is used in the bean:write tag:
MessageResources resources =
retrieveMessageResources(pageContext, bundle, false);
...
message = resources.getMessage(userLocale,
Thanks for the clarification!
After I sent the message a little light bulb came on and I realized
that I was using bean:write to output the content, so I did turn on the
filter and it worked
Thanks!
p.s. I guess women are right when they say 'verbalize' your problem lol
Actually those 2
Manish Singla wrote:
Hi
Use following
MessageResources mr = ((MessageResources)
request.getAttribute(Globals.MESSAGES_KEY));
what is Globals ??? I've tried it, but my java compiler does not knows it...
Instaed of
MessageResources mr =
Manish Singla wrote:
Hi
Use following
MessageResources mr = ((MessageResources)
request.getAttribute(Globals.MESSAGES_KEY));
what is Globals ??? I've tried it, but my java compiler does not knows it...
Instaed of
MessageResources mr =
Globals are in the struts.jar
org.apache.struts.Globals
Have a nice day
Michael
- Original Message -
From: Honza Spurn [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Tuesday, November 25, 2003 11:07 AM
Subject: Re: MessageResources
Hi
Use following
MessageResources mr = ((MessageResources)
request.getAttribute(Globals.MESSAGES_KEY));
Instaed of
MessageResources mr = request.getMessageResources();
HTH
Manish Singla
Honza Spurn wrote:
Hi there,
I'm able to read values from MessageResources in JSP files. But in special
I'm not clear on what you want to do. Do you want the name of the resources file?
On Thu, Nov 20, 2003 at 02:22:04PM -, Mitesh Patel wrote:
Hi,
Using Struts 1.1b2
Is it possible to get the message-resource parameter in the struts-config
file from a customTag?
message-resources
I need know/find out which ApplicationResource to
use.
any clearer?
Thanks
Mitesh
-Original Message-
From: Nick Heudecker [mailto:[EMAIL PROTECTED]
Sent: Thursday, November 20, 2003 2:49 PM
To: Struts Users Mailing List
Subject: Re: MessageResources...
I'm not clear on what you want
A brute force approach is to loop through the context objects looking for
ActionMessages or ActionError objects which contain the key you are looking
for. Of course, once you have it, just put the key somewhere for future
reference.
Edgar
-Original Message-
From: Mitesh Patel
Mitesh,
Why are you using a beta version when there is a released version available?
You can access the PageContext object and use methods on it to get the
objects that the Struts framework puts in your request object. Specifically,
you want the Globals.MESSAGE_KEY attribute.
This article
[mailto:[EMAIL PROTECTED]
Sent: Thursday, November 20, 2003 5:44 PM
To: 'Struts Users Mailing List'
Subject: RE: MessageResources...
Mitesh,
Why are you using a beta version when there is a released version available?
You can access the PageContext object and use methods on it to get the
objects
with the released
ones.
ApplicationConfig is deprecated in Struts 1.1. You should look at using
ModuleConfig.
-Richard
-Original Message-
From: Mitesh Patel [mailto:[EMAIL PROTECTED]
Sent: Thursday, November 20, 2003 9:55 AM
To: 'Struts Users Mailing List'
Subject: RE: MessageResources
You should really have the bundles named like this.
myresource
myresource_de (Germany)
myresourse_ko (Korea)
etc
One of the struts book will have a good line on this, or the i18n page at
the main web site.
Cheers
Simon
- Original Message -
From: Eric Chow [EMAIL PROTECTED]
To: Struts
MessageResources should not be used outside of the web tier. I'm not sure
where that code was used though. You could define a context parameter or
servlet init parameter that held the name of your resource bundle instead of
hardcoding.
David
From: Damm, Gary [EMAIL PROTECTED]
Reply-To:
What's the name of the properties file? Let's say
ApplicationResources.properties
This file has to be placed in the web-inf/classes directory.
At 08:10 03.10.2002 +0100, Alex Birch wrote:
Hi,
I can't find the answer to this anywhere but apologies if I missed
something obvious
I have the
it's in WEB-INF/classes
called ApplicationResources.properties
it works when I use bean:message key=prompt.login/ so I know it's loaded ok
it also works when I call the deprecated getResources()...
just when I add the request param or the request and key param I get null
but getResources is
-Original Message-
From: Tarun Sainanee [mailto:[EMAIL PROTECTED]]
Sent: Saturday, August 31, 2002 11:05 AM
Hi all,
I have been pretty happy using struts 1.0.2 for some time now. But now i
have a problem. Please help.
I know that we can use parameterized messages in the App
Hi Dave,
Try getServlet().getResources().getMessage(key);
Or getServlet().getResources().getMessage(locale, key);
Jon Ridgway
-Original Message-
From: David Wood [mailto:[EMAIL PROTECTED]]
Sent: 25 July 2002 15:20
To: Struts Users Mailing List
Subject: MessageResources from
Hello,
try HttpServletRequest.getParameter(key)
JML
[EMAIL PROTECTED]
-Original Message-
From: David Wood [mailto:[EMAIL PROTECTED]]
Sent: jeudi 25 juillet 2002 16:20
To: Struts Users Mailing List
Subject: MessageResources from ActionForm
I saw some posts with this question,
For the record, it turns out that the problem was related to a struts form
from my web war being found in my ejb jar. This played tricks on the mind of
the UCL, having it look in the wrong jar for the properties.
Be very careful about keeping your web and ejb classes exclusively in one or
the
-Original Message-
From: Brian Topping [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 08, 2002 2:49 PM
To: [EMAIL PROTECTED]
Subject: MessageResources problem under JBoss 3.0
Hiyas,
I'm looking at a classloader problem with JBoss 3 and Struts
1.1B1. It would
appear that
From: Martin Cooper
Subject: RE: MessageResources problem under JBoss 3.0
Date: Mon, 08 Jul 2002 15:18:56 -0700
-
---
-Original Message-
From: Brian Topping [mailto:[EMAIL PROTECTED]]
Subject
If you use the Struts Console to edit your config file
it will properly place the message-resources tag in
your file to comply with the DTD.
Struts Console:
http://www.jamesholmes.com/struts/
The thread you mention below explains what value to
set based on what you name your properties file and
to 1.1b ? Gotta
see if it's out of beta
state...
Barbara
- Original Message -
From: James Holmes [EMAIL PROTECTED]
To: Struts Users Mailing List
[EMAIL PROTECTED]
Sent: Friday, June 14, 2002 4:02 PM
Subject: Re: MessageResources configuration line to
struts-config.xml ?
If you
Users Mailing List [EMAIL PROTECTED]
Sent: Friday, June 14, 2002 4:09 PM
Subject: Re: MessageResources configuration line to struts-config.xml ?
Oops, sorry for the confusion. The
message-resources tag is new in 1.1 and thus is only
available in Struts 1.1b.
Here are links to both the 1.0
I agree, in fact, I wonder if it can be extended to load from
other means
such as xml, rdbms, or call to a url (ftp/http/whatever)
We implemented XMLMessageResources.java on our current
project.
Interwoven had problems getting stuff into .properties
files, so we had to read XML files
I agree, in fact, I wonder if it can be extended to load from other means
such as xml, rdbms, or call to a url (ftp/http/whatever)
James Mitchell
Software Engineer\Struts Evangelist
Struts-Atlanta, the Open Minded Developer Network
http://struts-atlanta.open-tools.org
ICQ: 27651409
AOLIM:
Take a look at the section on internationalization in the User's Guide,
http://jakarta.apache.org/struts/userGuide/building_view.html#i18n
-Original Message-
From: Todd Fulton [mailto:[EMAIL PROTECTED]]
Sent: Friday, November 02, 2001 10:38 AM
To: Struts Users Mailing List (E-mail)
:42 AM
To: 'Struts Users Mailing List'
Subject: RE: MessageResources bean - application scope
Take a look at the section on internationalization in the User's Guide,
http://jakarta.apache.org/struts/userGuide/building_view.html#i18n
-Original Message-
From: Todd Fulton [mailto:[EMAIL
29 matches
Mail list logo