In tiles taglib, I can see the role= attribute for customizing view base on user's role. I am wondering if this attribute is also available in other struts taglib like <html:link>. I want to have a list of links to be optionally displayed only when the user is logged in as certain role.
What else could I use to achieve this result. Would there be any ready made taglib supporting this?
Joined: Sep 06, 2005
I don't know if you can use the roles in the tags. That would be very nice if it could.
But other way to achieve what you want is using some flag attributes in the code (if a certain user logs on set this flag to a value and compare in your view on that flag), or using <logic:equals> on the current user attribute that contains users role (if the user is put in the session).