哦,忘了说,在jbuilder下是正常的,但是在ie运行就不行了,报得是NumberFormatException异常!代码片断:
<html:select property="selRegion" disabled="true">
  <logic:present name="regions"〉
     <html:options collection="regions"
                   property="regionId"
                   labelProperty="regionName"/>
  </logic:present>
</html:select>

解决方案 »

  1.   

    i have test your code in my computerthere is no error or exception!
      

  2.   

    onchange="javascript:return false;"  
    实在没办法就用脚本
      

  3.   

    <logic:present name="regions"〉是什么意思啊?
      

  4.   

    <html:select property="selRegion" disabled="true">
      
         <html:options collection="regions"
                       property="regionId"
                       labelProperty="regionName"/>
      
    </html:select>
    不需要<logic:present>循环了< html:options>本身就就把collection 中的东东全都表示出来
      

  5.   

    应该是
    <logic:present name="regions"〉
         <html:options collection="regions"
                       property="regionId"
                       labelProperty="regionName"/>
      </logic:present
    可能regions不存在,所以select 没有 options,从而导致出错
      

  6.   

    楼上的兄弟可能没看懂我的问题,我的意思是在disable=false的情况下是正常的,可以取道值,一旦disable=true就取不到值了!
      

  7.   

    你的意思是既想把值传递给服务器,但是又不详该字段被改动!
    你难道非得用select 吗?if (正常条件下){   显示标准的select标签!   }
    else(该字段不能被改动){
       
       <%=需要输出的值(该值是直接输出到页面的)%>
       <html:hidden property="该字段" value="<%=需要输出的值%>"/>
       }---------------------------------------
    该方法可以使你的字段既不被改动,有可以正常提交!
      

  8.   

    本来select就没有readonly的属性,只有用js去控制它