This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JSP and the fly likes c:if tag not working as expected Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "c:if tag not working as expected" Watch "c:if tag not working as expected" New topic

c:if tag not working as expected

Muhammad Imad Qureshi
Ranch Hand

Joined: Sep 13, 2005
Posts: 238

I have following code in my jsp

<bean efine id="sessionObj" name="mbzSessionForm" property="mbzSession" type="com.r911.core.model.MbzSession" />

<c:if test="${sessionObj.mbzStatus.sessionStatusId == 1}" >
value="<bean:message key=""/>" /> </c:if>

Can someone please tell me what is wrong with this code. I value exists because it works if I use staruts logic:equal tag. I want to use c:if because I want to check for multiple values which cannot be done using struts logic:equal tag which compares only one value at a time.

Consider Paul's rocket mass heater.
subject: c:if tag not working as expected
Similar Threads
logic:iterate and logic:radio confusion
Help with the tag library..
JSTL conversion for struts 1.1 code
How to replace a if(boolean) script with struts tag?
how to break from logic:iterate tag