M
michel.kowalczyk
Hi,
I am having problems with comparing two strings. The code should run
one action if they are equal or another if they are not equal. In my
version the 2 strings are always not equal eventhough they appear to me
equal.
This is my code:
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c"%>
<c:set var="currentEventString" scope="page" value="Something"/>
<html>
..
..
..
<c:choose>
<c:when test="${'${currentEventString}' eq Something}">
do something
</c:when>
<c
therwise>
do another thing
</c
therwise>
</c:choose>
..
..
..
</html>
Does this code have the right to work properly ??
TIA
Michael
I am having problems with comparing two strings. The code should run
one action if they are equal or another if they are not equal. In my
version the 2 strings are always not equal eventhough they appear to me
equal.
This is my code:
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c"%>
<c:set var="currentEventString" scope="page" value="Something"/>
<html>
..
..
..
<c:choose>
<c:when test="${'${currentEventString}' eq Something}">
do something
</c:when>
<c
do another thing
</c
</c:choose>
..
..
..
</html>
Does this code have the right to work properly ??
TIA
Michael