struts中的<html:select peoperty="aaa">...</html:select>

比如有一个:struts中的<html:selectpeoperty="aaa">...</html:select>请问,其中的property的值"aaa"是那里来的?... 比如有一个:struts中的<html:select peoperty="aaa">...</html:select>
请问,其中的property的值"aaa"是那里来的?
展开
 我来答
匿名用户
2013-12-18
展开全部
对选择框PROPERTY的设定和取得一般是有下面两种方法。1)利用FORM ,该当property作为FORM的一个成员。比如 FORM myform 定义property myproerty就可以像下面这样 <html:select name="myform" property="myproperty" >
<html:optionsCollection name="mylist"/>
</html:select>2)不利用FORM,动态设置Attribute 比如request.setAttribute("myproperty","1" ); <html:select property="myproperty" >
<html:optionsCollection name="mylist"/>
</html:select>就会表示mylist 里与1相匹配的数据。
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式