RE: Help please in ApplicationResources

2002-10-31 Thread James Mitchell
This would not be possible with the current API.

You can do this with your own implementation (as I have done), but that is
still just a hack.

James Mitchell
Software Engineer/Struts Evangelist
http://www.open-tools.org

"Only two things are infinite, the universe and human stupidity, and I'm not
sure about the former."
- Albert Einstein (1879-1955)


> -Original Message-
> From: Yann Verlynde [mailto:yverlynde@;oxade.com]
> Sent: Thursday, October 31, 2002 5:19 AM
> To: Struts Users Mailing List
> Subject: Re: Help please in ApplicationResources
>
>
> Hi Lucas,
>
> Thanks for the response but you don't understand my question, I
> think it is
> due to my english...;-)
> I have already one application resources file named
> ApplicationResources.properties so I use already a Resource Bundle but I
> want to write a page that print all the content of this ResourceBundle.
> I know that to have a property I must use:
> 
> So with that, I can print all the properties but I is very long and not
> flexible.
> It is not a very good solution because I put the name of the property
> 'email.protocol".
> So I would like a generic method or Tag to take back all the properties in
> an Array of the Resources Bundle in my JSP.
>
> Thanks in advance
> Yann
>
>
> - Original Message -
> From: "Lucas" <[EMAIL PROTECTED]>
> To: "'Struts Users Mailing List'" <[EMAIL PROTECTED]>
> Sent: Thursday, October 31, 2002 11:05 AM
> Subject: RE: Help please in ApplicationResources
>
>
> > Hi Yann,
> >
> > IMHO, from my understanding, the idea of having message resources bundle
> > in a separate text file is so that we do not have to change any codes
> > (JSP/Java) which means easier maintenance and more flexibility. So I
> > would suggest using a text file for a resource bundle and put it
> > anywhere below your WEB-INF/classes/dir1/dir2 as somefilename.properties
> > (I would put all the resources in the same directory) and then you can
> > access using
> >  (note
> > that the .properties extension is not needed).
> >
> > If you insist on using JSP then you should just use scriplet variables
> > like
> > <%
> > String emailProtocol = "POP3"
> > %>
> >
> > and call it using
> >
> > <%= emailProtocol %>
> >
> > Do I get your question right?
> >
> > Hope it helps,
> >
> > Lucas
> >
> >
> >
> > > -Original Message-
> > > From: Yann Verlynde [mailto:yverlynde@;oxade.com]
> > > Sent: Wednesday, October 30, 2002 11:58 PM
> > > To: Struts
> > > Subject: Help please in ApplicationResources
> > >
> > > If I want to have a message in a JSP, I use this code:
> > >  > bundle="APPLICATION_CONFIGURATION"/>
> > >
> > > But I want to have all the messages resources in my JSP,
> > > How can I do that please?
> > >
> > > Thanks in advance
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:struts-user-unsubscribe@;jakarta.apache.org>
> > For additional commands, e-mail:
> <mailto:struts-user-help@;jakarta.apache.org>
> >
>
>
> --
> To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail:
<mailto:struts-user-help@;jakarta.apache.org>



--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@;jakarta.apache.org>




Re: Help please in ApplicationResources

2002-10-31 Thread Yann Verlynde
Hi Lucas,

Thanks for the response but you don't understand my question, I think it is
due to my english...;-)
I have already one application resources file named
ApplicationResources.properties so I use already a Resource Bundle but I
want to write a page that print all the content of this ResourceBundle.
I know that to have a property I must use:

So with that, I can print all the properties but I is very long and not
flexible.
It is not a very good solution because I put the name of the property
'email.protocol".
So I would like a generic method or Tag to take back all the properties in
an Array of the Resources Bundle in my JSP.

Thanks in advance
Yann


- Original Message -
From: "Lucas" <[EMAIL PROTECTED]>
To: "'Struts Users Mailing List'" <[EMAIL PROTECTED]>
Sent: Thursday, October 31, 2002 11:05 AM
Subject: RE: Help please in ApplicationResources


> Hi Yann,
>
> IMHO, from my understanding, the idea of having message resources bundle
> in a separate text file is so that we do not have to change any codes
> (JSP/Java) which means easier maintenance and more flexibility. So I
> would suggest using a text file for a resource bundle and put it
> anywhere below your WEB-INF/classes/dir1/dir2 as somefilename.properties
> (I would put all the resources in the same directory) and then you can
> access using
>  (note
> that the .properties extension is not needed).
>
> If you insist on using JSP then you should just use scriplet variables
> like
> <%
> String emailProtocol = "POP3"
> %>
>
> and call it using
>
> <%= emailProtocol %>
>
> Do I get your question right?
>
> Hope it helps,
>
> Lucas
>
>
>
> > -Original Message-
> > From: Yann Verlynde [mailto:yverlynde@;oxade.com]
> > Sent: Wednesday, October 30, 2002 11:58 PM
> > To: Struts
> > Subject: Help please in ApplicationResources
> >
> > If I want to have a message in a JSP, I use this code:
> >  bundle="APPLICATION_CONFIGURATION"/>
> >
> > But I want to have all the messages resources in my JSP,
> > How can I do that please?
> >
> > Thanks in advance
>
>
>
> --
> To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@;jakarta.apache.org>
> For additional commands, e-mail:
<mailto:struts-user-help@;jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@;jakarta.apache.org>




RE: Help please in ApplicationResources

2002-10-31 Thread Lucas
Hi Yann,

IMHO, from my understanding, the idea of having message resources bundle
in a separate text file is so that we do not have to change any codes
(JSP/Java) which means easier maintenance and more flexibility. So I
would suggest using a text file for a resource bundle and put it
anywhere below your WEB-INF/classes/dir1/dir2 as somefilename.properties
(I would put all the resources in the same directory) and then you can
access using
 (note
that the .properties extension is not needed).

If you insist on using JSP then you should just use scriplet variables
like
<%
String emailProtocol = "POP3"
%>

and call it using

<%= emailProtocol %>

Do I get your question right?

Hope it helps,

Lucas



> -Original Message-
> From: Yann Verlynde [mailto:yverlynde@;oxade.com]
> Sent: Wednesday, October 30, 2002 11:58 PM
> To: Struts
> Subject: Help please in ApplicationResources
> 
> If I want to have a message in a JSP, I use this code:
> 
> 
> But I want to have all the messages resources in my JSP,
> How can I do that please?
> 
> Thanks in advance



--
To unsubscribe, e-mail:   
For additional commands, e-mail: