Hi maverickthinker,
Thanks for replying. I think formBackingObject() is used to assemble the custom object from returning data. But before the user can input in the form I need to display the form, which require me to send a model called 'survey' to it. I would like to know how to do it?
Here is what the survey view will look like:
Code:
<c:forEach items="${survey.questions}" var="question">
<li><c:out value="${question.questionDetail.questionContent}"></c:out></li>
<c:if test="${question.questionDetail.questionType eq '1'}">
<div class="feedback">
<input type="radio" name="${question.questionId}" value=1 />Excellent
<input type="radio" name="${question.questionId}" value=2 />Good
<input type="radio" name="${question.questionId}" value=3 />Average
<input type="radio" name="${question.questionId}" value=4 />Fair
<input type="radio" name="${question.questionId}" value=5 />Poor
<input type="radio" name="${question.questionId}" value=0 />N/A
</div>
</c:if>
<c:if test="${question.questionDetail.questionType eq '2'}">
<div class="feedback">
<textarea rows="5" cols="60" name="${question.questionId}"></textarea>
</div>
</c:if>
</c:forEach>