lundi 9 août 2021

How to output value in textarea using JSTL in JSP

I'm using JSTL in jsp and want to output value in textarea

<tr>
    <th scope="row">SMS Before Inst</th>
    <td colspan="7"><textarea cols="20" rows="5" placeholder="SMS Content" id=smsMessage name="smsMessage">
        Time setting is
        <c:choose>
            <c:when test="${CTSSessionCode=='M'}">
                Morning 
            </c:when>
            <c:when test="${CTSSessionCode=='E'}">
                 Everning
            </c:when>
            <c:otherwise>
                OTHER
            </c:otherwise>
        </c:choose>   
        Date
        <c:out value="${requestDate}" ></c:out> 
        ,We will contact later
    </textarea></td>
</tr>

within, CTSSessionCode = M is Morning, CTSSessionCode = E is Everning, and requestDate is date, but when i run it it output is blank and space character.

How to fix the problem ?

Aucun commentaire:

Enregistrer un commentaire