[2016-01-15][html][文字在网页中心 (水平垂直方向的中间) 显示]

[2016-01-15][html][文字在网页中心 (水平垂直方向的中间) 显示]
只需要构建一个表格,设置两个居中属性即可,如图,
(正中间!!!)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<html>
    <head>
        <title>正中间</title>
        <meta charset = "utf-8">
    </head>
    <body>
        <table width="100%" height="100%" cellpadding="0" cellspacing="0">
            <tr>
                <td valign="middle" align = "center">
                    <font size = 2>(正中间!!!)</font>
                </td>
            </tr>
        </table>
    </body>
</html>



来自为知笔记(Wiz)


posted on 2016-01-15 12:20  红洋  阅读(1411)  评论(0)    收藏  举报

导航