刚才我指的红色的那句是:
<html:option value=" <bean:write name=\"element\" property=\"key\"/> ">

解决方案 »

  1.   

    1.是不是根servlet容器有关系?
    2.这样就行了.不用那么复杂  Vector options = new Vector();
      options.add(new LabelValueBean("Label 0", "Value 0"));
      options.add(new LabelValueBean("Label 1", "Value 1"));
      options.add(new LabelValueBean("Label 2", "Value 2"));
      options.add(new LabelValueBean("Label 3", "Value 3"));
      options.add(new LabelValueBean("Label 4", "Value 4"));
      options.add(new LabelValueBean("Label 5", "Value 5"));
      options.add(new LabelValueBean("Label 6", "Value 6"));
      options.add(new LabelValueBean("Label 7", "Value 7"));
      options.add(new LabelValueBean("Label 8", "Value 8"));
      options.add(new LabelValueBean("Label 9", "Value 9"));
      pageContext.setAttribute("options", options);
    然后用:
          <html:select property="collectionSelect">
            <html:options collection="options" property="value" labelProperty="label"/>
          </html:select>