Woops, that logic:notEmpty example isn't right!  Not sure how you'd do it
with logic:notEmpty without the permissionsHashMap being a property of
another bean, say permissionsBean.  In that case it would look like this:

<logic:notEmpty name="permissionsBean" property="permissionsHashMap(Manage
Countries)">
  ... User has the "Manage Countries" permission
</logic:notEmpty>


> -----Original Message-----
> From: Jerome Jacobsen [mailto:[EMAIL PROTECTED]]
> Sent: Monday, February 03, 2003 9:19 AM
> To: Struts Users Mailing List
> Subject: RE: hashmaps and hash tables in JSPs
>
>
> <logic:notEmpty name="session" property="permissionsHashMap(Manage
> Countries)">
>  ... User has the "Manage Countries" permission
> </logic:notEmpty>
>
> Or with JSTL
>
> <c:if test="${permissionsHashMap['Manage Countries']}">
>  ... User has the "Manage Countries" permission
> </c:if>
>
>
> > -----Original Message-----
> > From: Jordan Thomas [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, February 03, 2003 9:02 AM
> > To: Struts User List
> > Subject: hashmaps and hash tables in JSPs
> >
> >
> > HI,
> >
> > I have a hastable or Hashmap of permissions that I want to use in my JSP
> > pages to determine what info is displayed to the user.
> >
> >
> >
> > For instance I want to have the following logic
> >
> > if permissionsHashMap has key "Manage Countires"
> >   then display this
> > if permissionsHashMap has key "Manage Logins"
> >   then display this
> >
> > etc....
> >
> > Is there a way to do this with the struts logic tags?
> >
> > thanks
> >
> > Jordan
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to