singh101
asked on
How to refer to a constant using JSTL
I have a java constant defined as follows:
public static final String ACCESS_ROLE="accessRole".
In a struts action class I set this attribute in a session sesssion.setAttribute(Cons tants.ACCE SS_ROLE, "adminrole");
In my JSP I am using JSTL. How could I use JSTL to check that the attribute exists in the session, i know how to do it using the actual string value such as
<c:if test="${(sessionScope.acce ssRole == 'true') }" > but how would I use Constant.ACCESS_ROLE in the if expression?
public static final String ACCESS_ROLE="accessRole".
In a struts action class I set this attribute in a session sesssion.setAttribute(Cons
In my JSP I am using JSTL. How could I use JSTL to check that the attribute exists in the session, i know how to do it using the actual string value such as
<c:if test="${(sessionScope.acce
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.