0
試圖抓住<spring:bind>
標籤。我正在嘗試打印一個字符串值。代碼看起來是這樣的:
春季MVC春季:綁定標籤
mySimpleBean myBean = presentStudent.getSubjects().getTeacherName();
String firstName = myBean.getTeacherFirstName()
從哪裏獲得從另一個豆 「presentStudent」 「爲myBean」。在jsp上我試過:
<spring:bind path="presentStudent.subjects.teacherName.teacherFirstName">
<input type="text" name="${status.expression}" value="${status.value}">
但它沒有打印任何東西。 也是「presentStudent」是commandObject這種形式:
<form:form id="stuTeachForm" name="stuTeachForm" method="post" commandName="presentStudent"
action="getStuTeachData.html">
Thanks Objects .. Will try this :) – t0mcat