Hello I am trying to set a name of a form input,a input type of text.If a post my form with a static name it will go to my servlet and be directed as defined.Though when I set my name on the text input to hold a jstl expression it ends with a null exception always.
I have valid data coming out in this form in display.
My page is using JSTL1.1 with a include
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<c:forEach var="item" items="${requestScope.productsAdd}" varStatus="status">
#<c:out value="${status.count}" />
<tr>
<td> <c:out value="${item.category}" escapeXml="false"/></td>
<td> <c:out value="${item.product_code}" escapeXml="false"/></td>
<td> <c:out value="${item.product_description}" escapeXml="false"/></td>
<td> <c:out value="${item.price}" escapeXml="false"/></td>
<td> <td> <input type="text" size="5" name="<c:out value='${item.product_code}'/>" /> </td>
<td class="centerChk">
</td>
</tr>
</c:forEach>
Here> name="<c:out value='${item.product_code}'/> is the culprit.
{code}
If if use say name="dukes" it will work.
Is there some escaping needed or should I use a different way?
Thanks