我想创建带有更多文本字段的
<s:div>
:
<s:div cssClass="div_position">
<s:textfield cssClass="position" id="position1" value="" name="position1" ></s:textfield>
<s:textfield cssClass="position" id="position2" value="" name="position2" ></s:textfield>
<s:textfield cssClass="position" id="position3" value="" name="position3" ></s:textfield>
<s:textfield cssClass="position" id="position4" value="" name="position4" ></s:textfield>
<s:textfield cssClass="position" id="position5" value="" name="position5" ></s:textfield>
</s:div>
班级
div_position
如下:
.div_position{ height:50px; overflow-y:Scroll; }
它不起作用,我只显示文本字段,但在
<s:div>
之外。
这对我有用
<s:div cssClass="div_position" cssStyle="height:50px;overflow-y:scroll;">
<s:textfield cssClass="position" id="position1" value="" name="position1" ></s:textfield>
<s:textfield cssClass="position" id="position2" value="" name="position2" ></s:textfield><br>
<s:textfield cssClass="position" id="position3" value="" name="position3" ></s:textfield>
<s:textfield cssClass="position" id="position4" value="" name="position4" ></s:textfield><br>
<s:textfield cssClass="position" id="position5" value="" name="position5" ></s:textfield>
</s:div>
因为我已经配置了
simple
主题。像我一样把这个放进去struts.xml
<constant name="struts.ui.theme" value="simple"/>