Home >Web Front-end >CSS Tutorial >How to align form labels on both ends with CSS (code example)
The content of this article is about how to achieve the alignment of both ends of the form label in CSS (code example). It has certain reference value. Friends in need can refer to it. I hope it will be helpful to you.
Main attributes:
text-align: justify;
text-align-last: justify; Seehttps://www .html.cn/book/css/properties/text/text-align-last.htm
Final effect:
Code:
li { clear: both; list-style: none; } .mark { display: block; float: left; overflow: hidden; width: 78px; height: 29px; padding-right: 10px; text-align: justify; text-align-last: justify; line-height: 2; }
English characters and numbers will not be aligned
The above is the detailed content of How to align form labels on both ends with CSS (code example). For more information, please follow other related articles on the PHP Chinese website!