我刚接触structs2架构,看到别人的代码,他这样写就可以显示student.id的值,但我不知道student.id在哪里定义?为什么这样写就能显示出student.id的值呢?请告知,谢谢了
<%@taglib prefix="s" uri="/struts-tags"%><html>
<body>
<s:property value="student.id"/>
</body>
</html>
<%@taglib prefix="s" uri="/struts-tags"%><html>
<body>
<s:property value="student.id"/>
</body>
</html>
你查看一下struts.xml就知道具体的action是哪个了。student是定义在action里的一个成员变量。
具体还有一个formbean与其对应