I am having the strangest problem. Here is my code:
<c:set var="updAlloc" value="" />
<if test="${1==0}" >
If Statement: ${1==0}
<c:set var="updAlloc" value="disabled" />
</if>
Update Alloc equals ${updAlloc}
This is the output:
If Statement: false
Update Alloc equals disabled
Originally, I was testing a different variable, but realized that "${1==0}" was not even working properly. As you can see, even though the EL statement in the test condition evaluates to false, it still executes the body of the if statement.
My only guess is that something is wrong with my if syntax so it is ignoring it entirely. Can somebody help me with this?