struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Allistair Crossley" <Allistair.Cross...@QAS.com>
Subject RE: Accessing java.util.Properties in JSP
Date Tue, 10 May 2005 12:13:23 GMT
instead of using a Properties object you could use a Map. That way, you can use JSTL associatively,
e.g

Map<String, String> myMap = new HashMap<String, String>();
myMap.put("aKey", "aVal");
request/session/application.setAttribute("myMap", myMap);

in your JSPs with EL

${request/session/applicationScope.myMap['aKey']}

Allistair.

> -----Original Message-----
> From: Richard Reyes [mailto:richards.list@gmail.com]
> Sent: 10 May 2005 12:57
> To: Struts Users Mailing List
> Subject: Re: Accessing java.util.Properties in JSP
> 
> 
> Okay I realized that I might use a static method. How do I call it in
> a JSP that is not like this...
> 
> <td><%Utilities.getDisplay( "BANNER_IMAGE" ) %></td>
> 
> 
> On 5/10/05, Richard Reyes <richards.list@gmail.com> wrote:
> > Hello Guys,
> > 
> > I have a properties object saved in my session and i need 
> to access it
> > in my jsp pages. can the bean tag handle this? how?
> > 
> > perhaps el?
> > 
> > thanks in advance
> > richard
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 


<FONT SIZE=1 FACE="VERDANA,ARIAL" COLOR=BLUE> 
-------------------------------------------------------
QAS Ltd.
Developers of QuickAddress Software
<a href="http://www.qas.com">www.qas.com</a>
Registered in England: No 2582055
Registered in Australia: No 082 851 474
-------------------------------------------------------
</FONT>


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message