读书人

请教jsp的combox的联动有关问题

发布时间: 2011-12-03 22:57:58 作者: rapoo

请教jsp的combox的联动问题
<td class= "TEXT4 "> 店名
<logic:present name= "CMB_SEARCH_LIST_SESSION ">
<bean:define id= "resultList " name= "CMB_SEARCH_LIST_SESSION " />

<html:select property= "hanId " style= "width:130px; " onchange= "ryoriSelect() ">
<html:options collection= "resultList " labelProperty= "hanTen " property= "hanId "> </html:options>
</html:select>
</logic:present>
</td>
在combox中定义了onchange事件,但是触发.do返回页面的时候combox默认的是第一个选项,而不是刚才选择的选项,这个问题如何解决?

[解决办法]
<html:select property= "hanId " style= "width:130px; " onchange= "ryoriSelect() ">
<html:options collection= "resultList " labelProperty= "hanTen " property= "hanId "> </html:options>
两个property一样?
[解决办法]
昏,还没出来啊...

<html:select property= "hanId " style= "width:130px; " onchange= "ryoriSelect() " value= "hanId ">
<html:options collection= "resultList " labelProperty= "hanTen " property= "hanId "> </html:options>

读书人网 >Java Web开发

热点推荐