css實現文字兩端對齊

代碼以下:css

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style type="text/css">
        div{
            width: 100px;
            border:solid blue 1px;
            text-align: justify;
            text-align-last: justify;
        }
    </style>
</head>
<body>
    <div>姓名</div>
    <div>手機號</div>
</body>
</html>
相關文章
相關標籤/搜索