踏实自动由formbean找到的。
你用<html:form action = "xxxxx">
把你的form包住,里边的填写框都改为<html:text property = "XXXX">
html:text对应于HTML的input type = "text" </html:form>
你用<html:form action = "xxxxx">
把你的form包住,里边的填写框都改为<html:text property = "XXXX">
html:text对应于HTML的input type = "text" </html:form>
在<html:form></html:form>中定义的property在formbean类中必须定义相应的数据类型,且必须有getter和setter.就这样而已,谢谢
这样的话是输入框中的输入传入到formBean中去了,但现在是一个已经存在的book对象(已经通过别的方式生成),因该用什么标签啊,html:text还可以吗?
你的book对象应该放到action文件中。