1、添加一个“返回到上一步”的按钮
<input type="button" onclick="history.go(-1);" value="返回" class="button">
2、div的使用:
<div align="center" style="margin:20px;"> <s:form action="user" > .... </s:form> </div>
3、fieldset+legend实现方框框住布局
<fieldset> <legend>登录界面</legend> <s:form action="user"> ... </s:form> </fieldset>
4、给表格将上边框
border-collapse设置边框的属性
separate:
默认值。边框会被分开。不会忽略border-spacing 和 empty-cells 属性。
collapse:
如果可能,边框会合并为一个单一的边框。会忽略border-spacing 和 empty-cells 属性。
inherit:
规定应该从父元素继承border-collapse属性的值。
table设置最外层的边框
table th表示标题的边框
table td设置每行内容的边框
<td>表示内容单元格
<th>则表示标题,一般用在一列的第一格,里面的内容会自动加粗加黑他们
jsp文件:
<head> <style> .table { border: 1px solid #000000; border-collapse: collapse; width =100%; } .table th { border: 1px solid #000000; border-collapse: collapse; } .table td { border: 1px solid #000000; border-collapse: collapse; } </style> </head> <body> <!-- <td>表示内容单元格 <th>则表示标题,一般用在一列的第一格,里面的内容会自动加粗加黑他们 --> <table class="table"> <tr> <th>名称(value)</th> <th>出生时间(value)</th> <th>技能(value)</th> </tr> <tr> <td align="center"><s:property value="name" /></td> <td align="center"><s:property value="birth" /></td> <td align="center"><s:property value="skill" /></td> </tr> </table> </body>
to be continued